home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995 February: Tool Chest / Dev.CD Feb 95 / Dev.CD Feb 95.toast / Tool Chest / Interfaces / Universal Interfaces 2.0a3 / Universal AIncludes / QuickTimeComponents.a < prev    next >
Encoding:
Text File  |  1994-11-11  |  116.5 KB  |  6,570 lines  |  [TEXT/MPS ]

  1. ;
  2. ;    File:        QuickTimeComponents.a
  3. ;
  4. ;    Copyright:    © 1984-1994 by Apple Computer, Inc.
  5. ;                All rights reserved.
  6. ;
  7. ;    Version:    Universal Interfaces 2.0a3  ETO #16, MPW prerelease.  Friday, November 11, 1994. 
  8. ;
  9. ;    Bugs?:        If you find a problem with this file, send the file and version
  10. ;                information (from above) and the problem description to:
  11. ;
  12. ;                    Internet:    apple.bugs@applelink.apple.com
  13. ;                    AppleLink:    APPLE.BUGS
  14. ;
  15. ;
  16.  
  17.     IF &TYPE('__QUICKTIMECOMPONENTS__') = 'UNDEFINED' THEN
  18. __QUICKTIMECOMPONENTS__ SET 1
  19.  
  20.  
  21.     IF &TYPE('__COMPONENTS__') = 'UNDEFINED' THEN
  22.     include 'Components.a'
  23.     ENDIF
  24. ;        include 'Types.a'                                            ;
  25. ;            include 'ConditionalMacros.a'                            ;
  26. ;        include 'MixedMode.a'                                        ;
  27.  
  28.     IF &TYPE('__IMAGECOMPRESSION__') = 'UNDEFINED' THEN
  29.     include 'ImageCompression.a'
  30.     ENDIF
  31. ;        include 'Quickdraw.a'                                        ;
  32. ;            include 'QuickdrawText.a'                                ;
  33. ;        include 'QDOffscreen.a'                                    ;
  34. ;            include 'Errors.a'                                        ;
  35. ;        include 'Windows.a'                                        ;
  36. ;            include 'Memory.a'                                        ;
  37. ;            include 'Events.a'                                        ;
  38. ;                include 'OSUtils.a'                                ;
  39. ;            include 'Controls.a'                                    ;
  40. ;                include 'Menus.a'                                    ;
  41. ;        include 'StandardFile.a'                                    ;
  42. ;            include 'Dialogs.a'                                    ;
  43. ;                include 'TextEdit.a'                                ;
  44. ;            include 'Files.a'                                        ;
  45.  
  46.     IF &TYPE('__MOVIES__') = 'UNDEFINED' THEN
  47.     include 'Movies.a'
  48.     ENDIF
  49. ;        include 'Aliases.a'                                        ;
  50. ;            include 'AppleTalk.a'                                    ;
  51.  
  52.     IF &TYPE('__VIDEO__') = 'UNDEFINED' THEN
  53.     include 'Video.a'
  54.     ENDIF
  55.  
  56. clockComponentType                EQU        'clok'
  57. systemTickClock                    EQU        'tick'                ; subtype: 60ths since boot        
  58. systemSecondClock                EQU        'seco'                ; subtype: seconds since 1904        
  59. systemMillisecondClock            EQU        'mill'                ; subtype: 1000ths since boot        
  60. systemMicrosecondClock            EQU        'micr'
  61.  
  62. kClockRateIsLinear                EQU        1
  63. kClockImplementsCallBacks        EQU        2
  64.  
  65. ;* These are Clock procedures *
  66.     IF GENERATING68K THEN
  67.         Macro
  68.         _ClockGetTime
  69.             dc.w     $2F3C
  70.             dc.w     $0004
  71.             dc.w     $0001
  72.             moveq    #0,d0
  73.             dc.w     $A82A
  74.         EndM
  75.     ELSE
  76.         IMPORT    ClockGetTime
  77.     ENDIF
  78.  
  79.     IF GENERATING68K THEN
  80.         Macro
  81.         _ClockNewCallBack
  82.             dc.w     $2F3C
  83.             dc.w     $0006
  84.             dc.w     $0002
  85.             moveq    #0,d0
  86.             dc.w     $A82A
  87.         EndM
  88.     ELSE
  89.         IMPORT    ClockNewCallBack
  90.     ENDIF
  91.  
  92.     IF GENERATING68K THEN
  93.         Macro
  94.         _ClockDisposeCallBack
  95.             dc.w     $2F3C
  96.             dc.w     $0004
  97.             dc.w     $0003
  98.             moveq    #0,d0
  99.             dc.w     $A82A
  100.         EndM
  101.     ELSE
  102.         IMPORT    ClockDisposeCallBack
  103.     ENDIF
  104.  
  105.     IF GENERATING68K THEN
  106.         Macro
  107.         _ClockCallMeWhen
  108.             dc.w     $2F3C
  109.             dc.w     $0010
  110.             dc.w     $0004
  111.             moveq    #0,d0
  112.             dc.w     $A82A
  113.         EndM
  114.     ELSE
  115.         IMPORT    ClockCallMeWhen
  116.     ENDIF
  117.  
  118.     IF GENERATING68K THEN
  119.         Macro
  120.         _ClockCancelCallBack
  121.             dc.w     $2F3C
  122.             dc.w     $0004
  123.             dc.w     $0005
  124.             moveq    #0,d0
  125.             dc.w     $A82A
  126.         EndM
  127.     ELSE
  128.         IMPORT    ClockCancelCallBack
  129.     ENDIF
  130.  
  131.     IF GENERATING68K THEN
  132.         Macro
  133.         _ClockRateChanged
  134.             dc.w     $2F3C
  135.             dc.w     $0004
  136.             dc.w     $0006
  137.             moveq    #0,d0
  138.             dc.w     $A82A
  139.         EndM
  140.     ELSE
  141.         IMPORT    ClockRateChanged
  142.     ENDIF
  143.  
  144.     IF GENERATING68K THEN
  145.         Macro
  146.         _ClockTimeChanged
  147.             dc.w     $2F3C
  148.             dc.w     $0004
  149.             dc.w     $0007
  150.             moveq    #0,d0
  151.             dc.w     $A82A
  152.         EndM
  153.     ELSE
  154.         IMPORT    ClockTimeChanged
  155.     ENDIF
  156.  
  157.     IF GENERATING68K THEN
  158.         Macro
  159.         _ClockSetTimeBase
  160.             dc.w     $2F3C
  161.             dc.w     $0004
  162.             dc.w     $0008
  163.             moveq    #0,d0
  164.             dc.w     $A82A
  165.         EndM
  166.     ELSE
  167.         IMPORT    ClockSetTimeBase
  168.     ENDIF
  169.  
  170.     IF GENERATING68K THEN
  171.         Macro
  172.         _ClockStartStopChanged
  173.             dc.w     $2F3C
  174.             dc.w     $0008
  175.             dc.w     $0009
  176.             moveq    #0,d0
  177.             dc.w     $A82A
  178.         EndM
  179.     ELSE
  180.         IMPORT    ClockStartStopChanged
  181.     ENDIF
  182.  
  183.     IF GENERATING68K THEN
  184.         Macro
  185.         _ClockGetRate
  186.             dc.w     $2F3C
  187.             dc.w     $0004
  188.             dc.w     $000A
  189.             moveq    #0,d0
  190.             dc.w     $A82A
  191.         EndM
  192.     ELSE
  193.         IMPORT    ClockGetRate
  194.     ENDIF
  195.  
  196. kClockGetTimeSelect                EQU        $1
  197. kClockNewCallBackSelect            EQU        $2
  198. kClockDisposeCallBackSelect        EQU        $3
  199. kClockCallMeWhenSelect            EQU        $4
  200. kClockCancelCallBackSelect        EQU        $5
  201. kClockRateChangedSelect            EQU        $6
  202. kClockTimeChangedSelect            EQU        $7
  203. kClockSetTimeBaseSelect            EQU        $8
  204. kClockStartStopChangedSelect    EQU        $9
  205. kClockGetRateSelect                EQU        $A
  206.  
  207. ;
  208. ;    General Sequence Grab stuff
  209. ;
  210. SeqGrabComponentType            EQU        'barg'
  211. SeqGrabChannelType                EQU        'sgch'
  212. SeqGrabPanelType                EQU        'sgpn'
  213. SeqGrabCompressionPanelType        EQU        'comp'
  214. SeqGrabSourcePanelType            EQU        'sour'
  215.  
  216. seqGrabToDisk                    EQU        1
  217. seqGrabToMemory                    EQU        2
  218. seqGrabDontUseTempMemory        EQU        4
  219. seqGrabAppendToFile                EQU        8
  220. seqGrabDontAddMovieResource        EQU        16
  221. seqGrabDontMakeMovie            EQU        32
  222. seqGrabPreExtendFile            EQU        64
  223. seqGrabDataProcIsInterruptSafe    EQU        128
  224. seqGrabDataProcDoesOverlappingReads EQU        256
  225.  
  226. seqGrabRecord                    EQU        1
  227. seqGrabPreview                    EQU        2
  228. seqGrabPlayDuringRecord            EQU        4
  229.  
  230. seqGrabHasBounds                EQU        1
  231. seqGrabHasVolume                EQU        2
  232. seqGrabHasDiscreteSamples        EQU        4
  233.  
  234. SeqGrabFrameInfo         RECORD    0
  235. frameOffset                 ds.l    1
  236. frameTime                 ds.l    1
  237. frameSize                 ds.l    1
  238. frameChannel             ds.l    1
  239. frameRefCon                 ds.l    1
  240. sizeof                     EQU    20
  241.                         ENDR
  242.  
  243.  
  244. grabPictOffScreen                EQU        1
  245. grabPictIgnoreClip                EQU        2
  246. grabPictCurrentImage            EQU        4
  247.  
  248. sgFlagControlledGrab            EQU        (1 << 0)
  249.  
  250. SGDeviceName             RECORD    0
  251. name                     ds.l    16
  252. icon                     ds.l    1
  253. flags                     ds.l    1
  254. refCon                     ds.l    1
  255. reserved                 ds.l    1                                    ; zero
  256. sizeof                     EQU    80
  257.                         ENDR
  258.  
  259.  
  260. sgDeviceNameFlagDeviceUnavailable EQU        (1 << 0)
  261.  
  262. SGDeviceListRecord         RECORD    0
  263. count                     ds.w    1
  264. selectedIndex             ds.w    1
  265. reserved                 ds.l    1                                    ; zero
  266. entry                     ds        SGDeviceName
  267. sizeof                     EQU    88
  268.                         ENDR
  269.  
  270.  
  271. sgDeviceListWithIcons            EQU        (1 << 0)
  272. sgDeviceListDontCheckAvailability EQU        (1 << 1)
  273.  
  274. seqGrabWriteAppend                EQU        0
  275. seqGrabWriteReserve                EQU        1
  276. seqGrabWriteFill                EQU        2
  277.  
  278. seqGrabUnpause                    EQU        0
  279. seqGrabPause                    EQU        1
  280. seqGrabPauseForMenu                EQU        3
  281.  
  282. channelFlagDontOpenResFile        EQU        2
  283. channelFlagHasDependency        EQU        4
  284.  
  285. sgPanelFlagForPanel                EQU        1
  286.  
  287. SGOutputRecord             RECORD    0
  288. data                     ds.l    1
  289. sizeof                     EQU    4
  290.                         ENDR
  291.  
  292.  
  293. channelPlayNormal                EQU        0
  294. channelPlayFast                    EQU        1
  295. channelPlayHighQuality            EQU        2
  296. channelPlayAllData                EQU        4
  297.  
  298.     IF GENERATING68K THEN
  299.         Macro
  300.         _SGInitialize
  301.             dc.w     $2F3C
  302.             dc.w     $0000
  303.             dc.w     $0001
  304.             moveq    #0,d0
  305.             dc.w     $A82A
  306.         EndM
  307.     ELSE
  308.         IMPORT    SGInitialize
  309.     ENDIF
  310.  
  311.     IF GENERATING68K THEN
  312.         Macro
  313.         _SGSetDataOutput
  314.             dc.w     $2F3C
  315.             dc.w     $0008
  316.             dc.w     $0002
  317.             moveq    #0,d0
  318.             dc.w     $A82A
  319.         EndM
  320.     ELSE
  321.         IMPORT    SGSetDataOutput
  322.     ENDIF
  323.  
  324.     IF GENERATING68K THEN
  325.         Macro
  326.         _SGGetDataOutput
  327.             dc.w     $2F3C
  328.             dc.w     $0008
  329.             dc.w     $0003
  330.             moveq    #0,d0
  331.             dc.w     $A82A
  332.         EndM
  333.     ELSE
  334.         IMPORT    SGGetDataOutput
  335.     ENDIF
  336.  
  337.     IF GENERATING68K THEN
  338.         Macro
  339.         _SGSetGWorld
  340.             dc.w     $2F3C
  341.             dc.w     $0008
  342.             dc.w     $0004
  343.             moveq    #0,d0
  344.             dc.w     $A82A
  345.         EndM
  346.     ELSE
  347.         IMPORT    SGSetGWorld
  348.     ENDIF
  349.  
  350.     IF GENERATING68K THEN
  351.         Macro
  352.         _SGGetGWorld
  353.             dc.w     $2F3C
  354.             dc.w     $0008
  355.             dc.w     $0005
  356.             moveq    #0,d0
  357.             dc.w     $A82A
  358.         EndM
  359.     ELSE
  360.         IMPORT    SGGetGWorld
  361.     ENDIF
  362.  
  363.     IF GENERATING68K THEN
  364.         Macro
  365.         _SGNewChannel
  366.             dc.w     $2F3C
  367.             dc.w     $0008
  368.             dc.w     $0006
  369.             moveq    #0,d0
  370.             dc.w     $A82A
  371.         EndM
  372.     ELSE
  373.         IMPORT    SGNewChannel
  374.     ENDIF
  375.  
  376.     IF GENERATING68K THEN
  377.         Macro
  378.         _SGDisposeChannel
  379.             dc.w     $2F3C
  380.             dc.w     $0004
  381.             dc.w     $0007
  382.             moveq    #0,d0
  383.             dc.w     $A82A
  384.         EndM
  385.     ELSE
  386.         IMPORT    SGDisposeChannel
  387.     ENDIF
  388.  
  389.     IF GENERATING68K THEN
  390.         Macro
  391.         _SGStartPreview
  392.             dc.w     $2F3C
  393.             dc.w     $0000
  394.             dc.w     $0010
  395.             moveq    #0,d0
  396.             dc.w     $A82A
  397.         EndM
  398.     ELSE
  399.         IMPORT    SGStartPreview
  400.     ENDIF
  401.  
  402.     IF GENERATING68K THEN
  403.         Macro
  404.         _SGStartRecord
  405.             dc.w     $2F3C
  406.             dc.w     $0000
  407.             dc.w     $0011
  408.             moveq    #0,d0
  409.             dc.w     $A82A
  410.         EndM
  411.     ELSE
  412.         IMPORT    SGStartRecord
  413.     ENDIF
  414.  
  415.     IF GENERATING68K THEN
  416.         Macro
  417.         _SGIdle
  418.             dc.w     $2F3C
  419.             dc.w     $0000
  420.             dc.w     $0012
  421.             moveq    #0,d0
  422.             dc.w     $A82A
  423.         EndM
  424.     ELSE
  425.         IMPORT    SGIdle
  426.     ENDIF
  427.  
  428.     IF GENERATING68K THEN
  429.         Macro
  430.         _SGStop
  431.             dc.w     $2F3C
  432.             dc.w     $0000
  433.             dc.w     $0013
  434.             moveq    #0,d0
  435.             dc.w     $A82A
  436.         EndM
  437.     ELSE
  438.         IMPORT    SGStop
  439.     ENDIF
  440.  
  441.     IF GENERATING68K THEN
  442.         Macro
  443.         _SGPause
  444.             dc.w     $2F3C
  445.             dc.w     $0002
  446.             dc.w     $0014
  447.             moveq    #0,d0
  448.             dc.w     $A82A
  449.         EndM
  450.     ELSE
  451.         IMPORT    SGPause
  452.     ENDIF
  453.  
  454.     IF GENERATING68K THEN
  455.         Macro
  456.         _SGPrepare
  457.             dc.w     $2F3C
  458.             dc.w     $0004
  459.             dc.w     $0015
  460.             moveq    #0,d0
  461.             dc.w     $A82A
  462.         EndM
  463.     ELSE
  464.         IMPORT    SGPrepare
  465.     ENDIF
  466.  
  467.     IF GENERATING68K THEN
  468.         Macro
  469.         _SGRelease
  470.             dc.w     $2F3C
  471.             dc.w     $0000
  472.             dc.w     $0016
  473.             moveq    #0,d0
  474.             dc.w     $A82A
  475.         EndM
  476.     ELSE
  477.         IMPORT    SGRelease
  478.     ENDIF
  479.  
  480.     IF GENERATING68K THEN
  481.         Macro
  482.         _SGGetMovie
  483.             dc.w     $2F3C
  484.             dc.w     $0000
  485.             dc.w     $0017
  486.             moveq    #0,d0
  487.             dc.w     $A82A
  488.         EndM
  489.     ELSE
  490.         IMPORT    SGGetMovie
  491.     ENDIF
  492.  
  493.     IF GENERATING68K THEN
  494.         Macro
  495.         _SGSetMaximumRecordTime
  496.             dc.w     $2F3C
  497.             dc.w     $0004
  498.             dc.w     $0018
  499.             moveq    #0,d0
  500.             dc.w     $A82A
  501.         EndM
  502.     ELSE
  503.         IMPORT    SGSetMaximumRecordTime
  504.     ENDIF
  505.  
  506.     IF GENERATING68K THEN
  507.         Macro
  508.         _SGGetMaximumRecordTime
  509.             dc.w     $2F3C
  510.             dc.w     $0004
  511.             dc.w     $0019
  512.             moveq    #0,d0
  513.             dc.w     $A82A
  514.         EndM
  515.     ELSE
  516.         IMPORT    SGGetMaximumRecordTime
  517.     ENDIF
  518.  
  519.     IF GENERATING68K THEN
  520.         Macro
  521.         _SGGetStorageSpaceRemaining
  522.             dc.w     $2F3C
  523.             dc.w     $0004
  524.             dc.w     $001A
  525.             moveq    #0,d0
  526.             dc.w     $A82A
  527.         EndM
  528.     ELSE
  529.         IMPORT    SGGetStorageSpaceRemaining
  530.     ENDIF
  531.  
  532.     IF GENERATING68K THEN
  533.         Macro
  534.         _SGGetTimeRemaining
  535.             dc.w     $2F3C
  536.             dc.w     $0004
  537.             dc.w     $001B
  538.             moveq    #0,d0
  539.             dc.w     $A82A
  540.         EndM
  541.     ELSE
  542.         IMPORT    SGGetTimeRemaining
  543.     ENDIF
  544.  
  545.     IF GENERATING68K THEN
  546.         Macro
  547.         _SGGrabPict
  548.             dc.w     $2F3C
  549.             dc.w     $000E
  550.             dc.w     $001C
  551.             moveq    #0,d0
  552.             dc.w     $A82A
  553.         EndM
  554.     ELSE
  555.         IMPORT    SGGrabPict
  556.     ENDIF
  557.  
  558.     IF GENERATING68K THEN
  559.         Macro
  560.         _SGGetLastMovieResID
  561.             dc.w     $2F3C
  562.             dc.w     $0004
  563.             dc.w     $001D
  564.             moveq    #0,d0
  565.             dc.w     $A82A
  566.         EndM
  567.     ELSE
  568.         IMPORT    SGGetLastMovieResID
  569.     ENDIF
  570.  
  571.     IF GENERATING68K THEN
  572.         Macro
  573.         _SGSetFlags
  574.             dc.w     $2F3C
  575.             dc.w     $0004
  576.             dc.w     $001E
  577.             moveq    #0,d0
  578.             dc.w     $A82A
  579.         EndM
  580.     ELSE
  581.         IMPORT    SGSetFlags
  582.     ENDIF
  583.  
  584.     IF GENERATING68K THEN
  585.         Macro
  586.         _SGGetFlags
  587.             dc.w     $2F3C
  588.             dc.w     $0004
  589.             dc.w     $001F
  590.             moveq    #0,d0
  591.             dc.w     $A82A
  592.         EndM
  593.     ELSE
  594.         IMPORT    SGGetFlags
  595.     ENDIF
  596.  
  597.     IF GENERATING68K THEN
  598.         Macro
  599.         _SGSetDataProc
  600.             dc.w     $2F3C
  601.             dc.w     $0008
  602.             dc.w     $0020
  603.             moveq    #0,d0
  604.             dc.w     $A82A
  605.         EndM
  606.     ELSE
  607.         IMPORT    SGSetDataProc
  608.     ENDIF
  609.  
  610.     IF GENERATING68K THEN
  611.         Macro
  612.         _SGNewChannelFromComponent
  613.             dc.w     $2F3C
  614.             dc.w     $0008
  615.             dc.w     $0021
  616.             moveq    #0,d0
  617.             dc.w     $A82A
  618.         EndM
  619.     ELSE
  620.         IMPORT    SGNewChannelFromComponent
  621.     ENDIF
  622.  
  623.     IF GENERATING68K THEN
  624.         Macro
  625.         _SGDisposeDeviceList
  626.             dc.w     $2F3C
  627.             dc.w     $0004
  628.             dc.w     $0022
  629.             moveq    #0,d0
  630.             dc.w     $A82A
  631.         EndM
  632.     ELSE
  633.         IMPORT    SGDisposeDeviceList
  634.     ENDIF
  635.  
  636.     IF GENERATING68K THEN
  637.         Macro
  638.         _SGAppendDeviceListToMenu
  639.             dc.w     $2F3C
  640.             dc.w     $0008
  641.             dc.w     $0023
  642.             moveq    #0,d0
  643.             dc.w     $A82A
  644.         EndM
  645.     ELSE
  646.         IMPORT    SGAppendDeviceListToMenu
  647.     ENDIF
  648.  
  649.     IF GENERATING68K THEN
  650.         Macro
  651.         _SGSetSettings
  652.             dc.w     $2F3C
  653.             dc.w     $0008
  654.             dc.w     $0024
  655.             moveq    #0,d0
  656.             dc.w     $A82A
  657.         EndM
  658.     ELSE
  659.         IMPORT    SGSetSettings
  660.     ENDIF
  661.  
  662.     IF GENERATING68K THEN
  663.         Macro
  664.         _SGGetSettings
  665.             dc.w     $2F3C
  666.             dc.w     $0008
  667.             dc.w     $0025
  668.             moveq    #0,d0
  669.             dc.w     $A82A
  670.         EndM
  671.     ELSE
  672.         IMPORT    SGGetSettings
  673.     ENDIF
  674.  
  675.     IF GENERATING68K THEN
  676.         Macro
  677.         _SGGetIndChannel
  678.             dc.w     $2F3C
  679.             dc.w     $000A
  680.             dc.w     $0026
  681.             moveq    #0,d0
  682.             dc.w     $A82A
  683.         EndM
  684.     ELSE
  685.         IMPORT    SGGetIndChannel
  686.     ENDIF
  687.  
  688.     IF GENERATING68K THEN
  689.         Macro
  690.         _SGUpdate
  691.             dc.w     $2F3C
  692.             dc.w     $0004
  693.             dc.w     $0027
  694.             moveq    #0,d0
  695.             dc.w     $A82A
  696.         EndM
  697.     ELSE
  698.         IMPORT    SGUpdate
  699.     ENDIF
  700.  
  701.     IF GENERATING68K THEN
  702.         Macro
  703.         _SGGetPause
  704.             dc.w     $2F3C
  705.             dc.w     $0004
  706.             dc.w     $0028
  707.             moveq    #0,d0
  708.             dc.w     $A82A
  709.         EndM
  710.     ELSE
  711.         IMPORT    SGGetPause
  712.     ENDIF
  713.  
  714.     IF GENERATING68K THEN
  715.         Macro
  716.         _SGSettingsDialog
  717.             dc.w     $2F3C
  718.             dc.w     $0016
  719.             dc.w     $0029
  720.             moveq    #0,d0
  721.             dc.w     $A82A
  722.         EndM
  723.     ELSE
  724.         IMPORT    SGSettingsDialog
  725.     ENDIF
  726.  
  727.     IF GENERATING68K THEN
  728.         Macro
  729.         _SGGetAlignmentProc
  730.             dc.w     $2F3C
  731.             dc.w     $0004
  732.             dc.w     $002A
  733.             moveq    #0,d0
  734.             dc.w     $A82A
  735.         EndM
  736.     ELSE
  737.         IMPORT    SGGetAlignmentProc
  738.     ENDIF
  739.  
  740.     IF GENERATING68K THEN
  741.         Macro
  742.         _SGSetChannelSettings
  743.             dc.w     $2F3C
  744.             dc.w     $000C
  745.             dc.w     $002B
  746.             moveq    #0,d0
  747.             dc.w     $A82A
  748.         EndM
  749.     ELSE
  750.         IMPORT    SGSetChannelSettings
  751.     ENDIF
  752.  
  753.     IF GENERATING68K THEN
  754.         Macro
  755.         _SGGetChannelSettings
  756.             dc.w     $2F3C
  757.             dc.w     $000C
  758.             dc.w     $002C
  759.             moveq    #0,d0
  760.             dc.w     $A82A
  761.         EndM
  762.     ELSE
  763.         IMPORT    SGGetChannelSettings
  764.     ENDIF
  765.  
  766.     IF GENERATING68K THEN
  767.         Macro
  768.         _SGGetMode
  769.             dc.w     $2F3C
  770.             dc.w     $0008
  771.             dc.w     $002D
  772.             moveq    #0,d0
  773.             dc.w     $A82A
  774.         EndM
  775.     ELSE
  776.         IMPORT    SGGetMode
  777.     ENDIF
  778.  
  779.     IF GENERATING68K THEN
  780.         Macro
  781.         _SGSetDataRef
  782.             dc.w     $2F3C
  783.             dc.w     $000C
  784.             dc.w     $002E
  785.             moveq    #0,d0
  786.             dc.w     $A82A
  787.         EndM
  788.     ELSE
  789.         IMPORT    SGSetDataRef
  790.     ENDIF
  791.  
  792.     IF GENERATING68K THEN
  793.         Macro
  794.         _SGGetDataRef
  795.             dc.w     $2F3C
  796.             dc.w     $000C
  797.             dc.w     $002F
  798.             moveq    #0,d0
  799.             dc.w     $A82A
  800.         EndM
  801.     ELSE
  802.         IMPORT    SGGetDataRef
  803.     ENDIF
  804.  
  805.     IF GENERATING68K THEN
  806.         Macro
  807.         _SGNewOutput
  808.             dc.w     $2F3C
  809.             dc.w     $0010
  810.             dc.w     $0030
  811.             moveq    #0,d0
  812.             dc.w     $A82A
  813.         EndM
  814.     ELSE
  815.         IMPORT    SGNewOutput
  816.     ENDIF
  817.  
  818.     IF GENERATING68K THEN
  819.         Macro
  820.         _SGDisposeOutput
  821.             dc.w     $2F3C
  822.             dc.w     $0004
  823.             dc.w     $0031
  824.             moveq    #0,d0
  825.             dc.w     $A82A
  826.         EndM
  827.     ELSE
  828.         IMPORT    SGDisposeOutput
  829.     ENDIF
  830.  
  831.     IF GENERATING68K THEN
  832.         Macro
  833.         _SGSetOutputFlags
  834.             dc.w     $2F3C
  835.             dc.w     $0008
  836.             dc.w     $0032
  837.             moveq    #0,d0
  838.             dc.w     $A82A
  839.         EndM
  840.     ELSE
  841.         IMPORT    SGSetOutputFlags
  842.     ENDIF
  843.  
  844.     IF GENERATING68K THEN
  845.         Macro
  846.         _SGSetChannelOutput
  847.             dc.w     $2F3C
  848.             dc.w     $0008
  849.             dc.w     $0033
  850.             moveq    #0,d0
  851.             dc.w     $A82A
  852.         EndM
  853.     ELSE
  854.         IMPORT    SGSetChannelOutput
  855.     ENDIF
  856.  
  857.     IF GENERATING68K THEN
  858.         Macro
  859.         _SGGetDataOutputStorageSpaceRemaining
  860.             dc.w     $2F3C
  861.             dc.w     $0008
  862.             dc.w     $0034
  863.             moveq    #0,d0
  864.             dc.w     $A82A
  865.         EndM
  866.     ELSE
  867.         IMPORT    SGGetDataOutputStorageSpaceRemaining
  868.     ENDIF
  869.  
  870. ;
  871. ;    calls from Channel to seqGrab
  872. ;
  873.     IF GENERATING68K THEN
  874.         Macro
  875.         _SGWriteMovieData
  876.             dc.w     $2F3C
  877.             dc.w     $0010
  878.             dc.w     $0100
  879.             moveq    #0,d0
  880.             dc.w     $A82A
  881.         EndM
  882.     ELSE
  883.         IMPORT    SGWriteMovieData
  884.     ENDIF
  885.  
  886.     IF GENERATING68K THEN
  887.         Macro
  888.         _SGAddFrameReference
  889.             dc.w     $2F3C
  890.             dc.w     $0004
  891.             dc.w     $0101
  892.             moveq    #0,d0
  893.             dc.w     $A82A
  894.         EndM
  895.     ELSE
  896.         IMPORT    SGAddFrameReference
  897.     ENDIF
  898.  
  899.     IF GENERATING68K THEN
  900.         Macro
  901.         _SGGetNextFrameReference
  902.             dc.w     $2F3C
  903.             dc.w     $000C
  904.             dc.w     $0102
  905.             moveq    #0,d0
  906.             dc.w     $A82A
  907.         EndM
  908.     ELSE
  909.         IMPORT    SGGetNextFrameReference
  910.     ENDIF
  911.  
  912.     IF GENERATING68K THEN
  913.         Macro
  914.         _SGGetTimeBase
  915.             dc.w     $2F3C
  916.             dc.w     $0004
  917.             dc.w     $0103
  918.             moveq    #0,d0
  919.             dc.w     $A82A
  920.         EndM
  921.     ELSE
  922.         IMPORT    SGGetTimeBase
  923.     ENDIF
  924.  
  925.     IF GENERATING68K THEN
  926.         Macro
  927.         _SGSortDeviceList
  928.             dc.w     $2F3C
  929.             dc.w     $0004
  930.             dc.w     $0104
  931.             moveq    #0,d0
  932.             dc.w     $A82A
  933.         EndM
  934.     ELSE
  935.         IMPORT    SGSortDeviceList
  936.     ENDIF
  937.  
  938.     IF GENERATING68K THEN
  939.         Macro
  940.         _SGAddMovieData
  941.             dc.w     $2F3C
  942.             dc.w     $001A
  943.             dc.w     $0105
  944.             moveq    #0,d0
  945.             dc.w     $A82A
  946.         EndM
  947.     ELSE
  948.         IMPORT    SGAddMovieData
  949.     ENDIF
  950.  
  951.     IF GENERATING68K THEN
  952.         Macro
  953.         _SGChangedSource
  954.             dc.w     $2F3C
  955.             dc.w     $0004
  956.             dc.w     $0106
  957.             moveq    #0,d0
  958.             dc.w     $A82A
  959.         EndM
  960.     ELSE
  961.         IMPORT    SGChangedSource
  962.     ENDIF
  963.  
  964. ;** Sequence Grab CHANNEL Component Stuff **
  965.     IF GENERATING68K THEN
  966.         Macro
  967.         _SGSetChannelUsage
  968.             dc.w     $2F3C
  969.             dc.w     $0004
  970.             dc.w     $0080
  971.             moveq    #0,d0
  972.             dc.w     $A82A
  973.         EndM
  974.     ELSE
  975.         IMPORT    SGSetChannelUsage
  976.     ENDIF
  977.  
  978.     IF GENERATING68K THEN
  979.         Macro
  980.         _SGGetChannelUsage
  981.             dc.w     $2F3C
  982.             dc.w     $0004
  983.             dc.w     $0081
  984.             moveq    #0,d0
  985.             dc.w     $A82A
  986.         EndM
  987.     ELSE
  988.         IMPORT    SGGetChannelUsage
  989.     ENDIF
  990.  
  991.     IF GENERATING68K THEN
  992.         Macro
  993.         _SGSetChannelBounds
  994.             dc.w     $2F3C
  995.             dc.w     $0004
  996.             dc.w     $0082
  997.             moveq    #0,d0
  998.             dc.w     $A82A
  999.         EndM
  1000.     ELSE
  1001.         IMPORT    SGSetChannelBounds
  1002.     ENDIF
  1003.  
  1004.     IF GENERATING68K THEN
  1005.         Macro
  1006.         _SGGetChannelBounds
  1007.             dc.w     $2F3C
  1008.             dc.w     $0004
  1009.             dc.w     $0083
  1010.             moveq    #0,d0
  1011.             dc.w     $A82A
  1012.         EndM
  1013.     ELSE
  1014.         IMPORT    SGGetChannelBounds
  1015.     ENDIF
  1016.  
  1017.     IF GENERATING68K THEN
  1018.         Macro
  1019.         _SGSetChannelVolume
  1020.             dc.w     $2F3C
  1021.             dc.w     $0002
  1022.             dc.w     $0084
  1023.             moveq    #0,d0
  1024.             dc.w     $A82A
  1025.         EndM
  1026.     ELSE
  1027.         IMPORT    SGSetChannelVolume
  1028.     ENDIF
  1029.  
  1030.     IF GENERATING68K THEN
  1031.         Macro
  1032.         _SGGetChannelVolume
  1033.             dc.w     $2F3C
  1034.             dc.w     $0004
  1035.             dc.w     $0085
  1036.             moveq    #0,d0
  1037.             dc.w     $A82A
  1038.         EndM
  1039.     ELSE
  1040.         IMPORT    SGGetChannelVolume
  1041.     ENDIF
  1042.  
  1043.     IF GENERATING68K THEN
  1044.         Macro
  1045.         _SGGetChannelInfo
  1046.             dc.w     $2F3C
  1047.             dc.w     $0004
  1048.             dc.w     $0086
  1049.             moveq    #0,d0
  1050.             dc.w     $A82A
  1051.         EndM
  1052.     ELSE
  1053.         IMPORT    SGGetChannelInfo
  1054.     ENDIF
  1055.  
  1056.     IF GENERATING68K THEN
  1057.         Macro
  1058.         _SGSetChannelPlayFlags
  1059.             dc.w     $2F3C
  1060.             dc.w     $0004
  1061.             dc.w     $0087
  1062.             moveq    #0,d0
  1063.             dc.w     $A82A
  1064.         EndM
  1065.     ELSE
  1066.         IMPORT    SGSetChannelPlayFlags
  1067.     ENDIF
  1068.  
  1069.     IF GENERATING68K THEN
  1070.         Macro
  1071.         _SGGetChannelPlayFlags
  1072.             dc.w     $2F3C
  1073.             dc.w     $0004
  1074.             dc.w     $0088
  1075.             moveq    #0,d0
  1076.             dc.w     $A82A
  1077.         EndM
  1078.     ELSE
  1079.         IMPORT    SGGetChannelPlayFlags
  1080.     ENDIF
  1081.  
  1082.     IF GENERATING68K THEN
  1083.         Macro
  1084.         _SGSetChannelMaxFrames
  1085.             dc.w     $2F3C
  1086.             dc.w     $0004
  1087.             dc.w     $0089
  1088.             moveq    #0,d0
  1089.             dc.w     $A82A
  1090.         EndM
  1091.     ELSE
  1092.         IMPORT    SGSetChannelMaxFrames
  1093.     ENDIF
  1094.  
  1095.     IF GENERATING68K THEN
  1096.         Macro
  1097.         _SGGetChannelMaxFrames
  1098.             dc.w     $2F3C
  1099.             dc.w     $0004
  1100.             dc.w     $008A
  1101.             moveq    #0,d0
  1102.             dc.w     $A82A
  1103.         EndM
  1104.     ELSE
  1105.         IMPORT    SGGetChannelMaxFrames
  1106.     ENDIF
  1107.  
  1108.     IF GENERATING68K THEN
  1109.         Macro
  1110.         _SGSetChannelRefCon
  1111.             dc.w     $2F3C
  1112.             dc.w     $0004
  1113.             dc.w     $008B
  1114.             moveq    #0,d0
  1115.             dc.w     $A82A
  1116.         EndM
  1117.     ELSE
  1118.         IMPORT    SGSetChannelRefCon
  1119.     ENDIF
  1120.  
  1121.     IF GENERATING68K THEN
  1122.         Macro
  1123.         _SGSetChannelClip
  1124.             dc.w     $2F3C
  1125.             dc.w     $0004
  1126.             dc.w     $008C
  1127.             moveq    #0,d0
  1128.             dc.w     $A82A
  1129.         EndM
  1130.     ELSE
  1131.         IMPORT    SGSetChannelClip
  1132.     ENDIF
  1133.  
  1134.     IF GENERATING68K THEN
  1135.         Macro
  1136.         _SGGetChannelClip
  1137.             dc.w     $2F3C
  1138.             dc.w     $0004
  1139.             dc.w     $008D
  1140.             moveq    #0,d0
  1141.             dc.w     $A82A
  1142.         EndM
  1143.     ELSE
  1144.         IMPORT    SGGetChannelClip
  1145.     ENDIF
  1146.  
  1147.     IF GENERATING68K THEN
  1148.         Macro
  1149.         _SGGetChannelSampleDescription
  1150.             dc.w     $2F3C
  1151.             dc.w     $0004
  1152.             dc.w     $008E
  1153.             moveq    #0,d0
  1154.             dc.w     $A82A
  1155.         EndM
  1156.     ELSE
  1157.         IMPORT    SGGetChannelSampleDescription
  1158.     ENDIF
  1159.  
  1160.     IF GENERATING68K THEN
  1161.         Macro
  1162.         _SGGetChannelDeviceList
  1163.             dc.w     $2F3C
  1164.             dc.w     $0008
  1165.             dc.w     $008F
  1166.             moveq    #0,d0
  1167.             dc.w     $A82A
  1168.         EndM
  1169.     ELSE
  1170.         IMPORT    SGGetChannelDeviceList
  1171.     ENDIF
  1172.  
  1173.     IF GENERATING68K THEN
  1174.         Macro
  1175.         _SGSetChannelDevice
  1176.             dc.w     $2F3C
  1177.             dc.w     $0004
  1178.             dc.w     $0090
  1179.             moveq    #0,d0
  1180.             dc.w     $A82A
  1181.         EndM
  1182.     ELSE
  1183.         IMPORT    SGSetChannelDevice
  1184.     ENDIF
  1185.  
  1186.     IF GENERATING68K THEN
  1187.         Macro
  1188.         _SGSetChannelMatrix
  1189.             dc.w     $2F3C
  1190.             dc.w     $0004
  1191.             dc.w     $0091
  1192.             moveq    #0,d0
  1193.             dc.w     $A82A
  1194.         EndM
  1195.     ELSE
  1196.         IMPORT    SGSetChannelMatrix
  1197.     ENDIF
  1198.  
  1199.     IF GENERATING68K THEN
  1200.         Macro
  1201.         _SGGetChannelMatrix
  1202.             dc.w     $2F3C
  1203.             dc.w     $0004
  1204.             dc.w     $0092
  1205.             moveq    #0,d0
  1206.             dc.w     $A82A
  1207.         EndM
  1208.     ELSE
  1209.         IMPORT    SGGetChannelMatrix
  1210.     ENDIF
  1211.  
  1212.     IF GENERATING68K THEN
  1213.         Macro
  1214.         _SGGetChannelTimeScale
  1215.             dc.w     $2F3C
  1216.             dc.w     $0004
  1217.             dc.w     $0093
  1218.             moveq    #0,d0
  1219.             dc.w     $A82A
  1220.         EndM
  1221.     ELSE
  1222.         IMPORT    SGGetChannelTimeScale
  1223.     ENDIF
  1224.  
  1225.     IF GENERATING68K THEN
  1226.         Macro
  1227.         _SGChannelPutPicture
  1228.             dc.w     $2F3C
  1229.             dc.w     $0000
  1230.             dc.w     $0094
  1231.             moveq    #0,d0
  1232.             dc.w     $A82A
  1233.         EndM
  1234.     ELSE
  1235.         IMPORT    SGChannelPutPicture
  1236.     ENDIF
  1237.  
  1238.     IF GENERATING68K THEN
  1239.         Macro
  1240.         _SGChannelSetRequestedDataRate
  1241.             dc.w     $2F3C
  1242.             dc.w     $0004
  1243.             dc.w     $0095
  1244.             moveq    #0,d0
  1245.             dc.w     $A82A
  1246.         EndM
  1247.     ELSE
  1248.         IMPORT    SGChannelSetRequestedDataRate
  1249.     ENDIF
  1250.  
  1251.     IF GENERATING68K THEN
  1252.         Macro
  1253.         _SGChannelGetRequestedDataRate
  1254.             dc.w     $2F3C
  1255.             dc.w     $0004
  1256.             dc.w     $0096
  1257.             moveq    #0,d0
  1258.             dc.w     $A82A
  1259.         EndM
  1260.     ELSE
  1261.         IMPORT    SGChannelGetRequestedDataRate
  1262.     ENDIF
  1263.  
  1264.     IF GENERATING68K THEN
  1265.         Macro
  1266.         _SGChannelSetDataSourceName
  1267.             dc.w     $2F3C
  1268.             dc.w     $0006
  1269.             dc.w     $0097
  1270.             moveq    #0,d0
  1271.             dc.w     $A82A
  1272.         EndM
  1273.     ELSE
  1274.         IMPORT    SGChannelSetDataSourceName
  1275.     ENDIF
  1276.  
  1277.     IF GENERATING68K THEN
  1278.         Macro
  1279.         _SGChannelGetDataSourceName
  1280.             dc.w     $2F3C
  1281.             dc.w     $0008
  1282.             dc.w     $0098
  1283.             moveq    #0,d0
  1284.             dc.w     $A82A
  1285.         EndM
  1286.     ELSE
  1287.         IMPORT    SGChannelGetDataSourceName
  1288.     ENDIF
  1289.  
  1290. ;
  1291. ;    calls from seqGrab to Channel
  1292. ;
  1293.     IF GENERATING68K THEN
  1294.         Macro
  1295.         _SGInitChannel
  1296.             dc.w     $2F3C
  1297.             dc.w     $0004
  1298.             dc.w     $0180
  1299.             moveq    #0,d0
  1300.             dc.w     $A82A
  1301.         EndM
  1302.     ELSE
  1303.         IMPORT    SGInitChannel
  1304.     ENDIF
  1305.  
  1306.     IF GENERATING68K THEN
  1307.         Macro
  1308.         _SGWriteSamples
  1309.             dc.w     $2F3C
  1310.             dc.w     $0008
  1311.             dc.w     $0181
  1312.             moveq    #0,d0
  1313.             dc.w     $A82A
  1314.         EndM
  1315.     ELSE
  1316.         IMPORT    SGWriteSamples
  1317.     ENDIF
  1318.  
  1319.     IF GENERATING68K THEN
  1320.         Macro
  1321.         _SGGetDataRate
  1322.             dc.w     $2F3C
  1323.             dc.w     $0004
  1324.             dc.w     $0182
  1325.             moveq    #0,d0
  1326.             dc.w     $A82A
  1327.         EndM
  1328.     ELSE
  1329.         IMPORT    SGGetDataRate
  1330.     ENDIF
  1331.  
  1332.     IF GENERATING68K THEN
  1333.         Macro
  1334.         _SGAlignChannelRect
  1335.             dc.w     $2F3C
  1336.             dc.w     $0004
  1337.             dc.w     $0183
  1338.             moveq    #0,d0
  1339.             dc.w     $A82A
  1340.         EndM
  1341.     ELSE
  1342.         IMPORT    SGAlignChannelRect
  1343.     ENDIF
  1344.  
  1345. ;
  1346. ;    Dorky dialog panel calls
  1347. ;
  1348.     IF GENERATING68K THEN
  1349.         Macro
  1350.         _SGPanelGetDitl
  1351.             dc.w     $2F3C
  1352.             dc.w     $0004
  1353.             dc.w     $0200
  1354.             moveq    #0,d0
  1355.             dc.w     $A82A
  1356.         EndM
  1357.     ELSE
  1358.         IMPORT    SGPanelGetDitl
  1359.     ENDIF
  1360.  
  1361.     IF GENERATING68K THEN
  1362.         Macro
  1363.         _SGPanelGetTitle
  1364.             dc.w     $2F3C
  1365.             dc.w     $0004
  1366.             dc.w     $0201
  1367.             moveq    #0,d0
  1368.             dc.w     $A82A
  1369.         EndM
  1370.     ELSE
  1371.         IMPORT    SGPanelGetTitle
  1372.     ENDIF
  1373.  
  1374.     IF GENERATING68K THEN
  1375.         Macro
  1376.         _SGPanelCanRun
  1377.             dc.w     $2F3C
  1378.             dc.w     $0004
  1379.             dc.w     $0202
  1380.             moveq    #0,d0
  1381.             dc.w     $A82A
  1382.         EndM
  1383.     ELSE
  1384.         IMPORT    SGPanelCanRun
  1385.     ENDIF
  1386.  
  1387.     IF GENERATING68K THEN
  1388.         Macro
  1389.         _SGPanelInstall
  1390.             dc.w     $2F3C
  1391.             dc.w     $000A
  1392.             dc.w     $0203
  1393.             moveq    #0,d0
  1394.             dc.w     $A82A
  1395.         EndM
  1396.     ELSE
  1397.         IMPORT    SGPanelInstall
  1398.     ENDIF
  1399.  
  1400.     IF GENERATING68K THEN
  1401.         Macro
  1402.         _SGPanelEvent
  1403.             dc.w     $2F3C
  1404.             dc.w     $0016
  1405.             dc.w     $0204
  1406.             moveq    #0,d0
  1407.             dc.w     $A82A
  1408.         EndM
  1409.     ELSE
  1410.         IMPORT    SGPanelEvent
  1411.     ENDIF
  1412.  
  1413.     IF GENERATING68K THEN
  1414.         Macro
  1415.         _SGPanelItem
  1416.             dc.w     $2F3C
  1417.             dc.w     $000C
  1418.             dc.w     $0205
  1419.             moveq    #0,d0
  1420.             dc.w     $A82A
  1421.         EndM
  1422.     ELSE
  1423.         IMPORT    SGPanelItem
  1424.     ENDIF
  1425.  
  1426.     IF GENERATING68K THEN
  1427.         Macro
  1428.         _SGPanelRemove
  1429.             dc.w     $2F3C
  1430.             dc.w     $000A
  1431.             dc.w     $0206
  1432.             moveq    #0,d0
  1433.             dc.w     $A82A
  1434.         EndM
  1435.     ELSE
  1436.         IMPORT    SGPanelRemove
  1437.     ENDIF
  1438.  
  1439.     IF GENERATING68K THEN
  1440.         Macro
  1441.         _SGPanelSetGrabber
  1442.             dc.w     $2F3C
  1443.             dc.w     $0004
  1444.             dc.w     $0207
  1445.             moveq    #0,d0
  1446.             dc.w     $A82A
  1447.         EndM
  1448.     ELSE
  1449.         IMPORT    SGPanelSetGrabber
  1450.     ENDIF
  1451.  
  1452.     IF GENERATING68K THEN
  1453.         Macro
  1454.         _SGPanelSetResFile
  1455.             dc.w     $2F3C
  1456.             dc.w     $0002
  1457.             dc.w     $0208
  1458.             moveq    #0,d0
  1459.             dc.w     $A82A
  1460.         EndM
  1461.     ELSE
  1462.         IMPORT    SGPanelSetResFile
  1463.     ENDIF
  1464.  
  1465.     IF GENERATING68K THEN
  1466.         Macro
  1467.         _SGPanelGetSettings
  1468.             dc.w     $2F3C
  1469.             dc.w     $000C
  1470.             dc.w     $0209
  1471.             moveq    #0,d0
  1472.             dc.w     $A82A
  1473.         EndM
  1474.     ELSE
  1475.         IMPORT    SGPanelGetSettings
  1476.     ENDIF
  1477.  
  1478.     IF GENERATING68K THEN
  1479.         Macro
  1480.         _SGPanelSetSettings
  1481.             dc.w     $2F3C
  1482.             dc.w     $000C
  1483.             dc.w     $020A
  1484.             moveq    #0,d0
  1485.             dc.w     $A82A
  1486.         EndM
  1487.     ELSE
  1488.         IMPORT    SGPanelSetSettings
  1489.     ENDIF
  1490.  
  1491.     IF GENERATING68K THEN
  1492.         Macro
  1493.         _SGPanelValidateInput
  1494.             dc.w     $2F3C
  1495.             dc.w     $0004
  1496.             dc.w     $020B
  1497.             moveq    #0,d0
  1498.             dc.w     $A82A
  1499.         EndM
  1500.     ELSE
  1501.         IMPORT    SGPanelValidateInput
  1502.     ENDIF
  1503.  
  1504.     IF GENERATING68K THEN
  1505.         Macro
  1506.         _SGPanelSetEventFilter
  1507.             dc.w     $2F3C
  1508.             dc.w     $0008
  1509.             dc.w     $020C
  1510.             moveq    #0,d0
  1511.             dc.w     $A82A
  1512.         EndM
  1513.     ELSE
  1514.         IMPORT    SGPanelSetEventFilter
  1515.     ENDIF
  1516.  
  1517. ;** Sequence Grab VIDEO CHANNEL Component Stuff **
  1518. ;
  1519. ;    Video stuff
  1520. ;
  1521. SGCompressInfo             RECORD    0
  1522. buffer                     ds.l    1
  1523. bufferSize                 ds.l    1
  1524. similarity                 ds.b    1
  1525. reserved                 ds.b    1
  1526. sizeof                     EQU    10
  1527.                         ENDR
  1528.  
  1529. VideoBottles             RECORD    0
  1530. procCount                 ds.w    1
  1531. grabProc                 ds.l    1
  1532. grabCompleteProc         ds.l    1
  1533. displayProc                 ds.l    1
  1534. compressProc             ds.l    1
  1535. compressCompleteProc     ds.l    1
  1536. addFrameProc             ds.l    1
  1537. transferFrameProc         ds.l    1
  1538. grabCompressCompleteProc ds.l    1
  1539. displayCompressProc         ds.l    1
  1540. sizeof                     EQU    38
  1541.                         ENDR
  1542.  
  1543.     IF GENERATING68K THEN
  1544.         Macro
  1545.         _SGGetSrcVideoBounds
  1546.             dc.w     $2F3C
  1547.             dc.w     $0004
  1548.             dc.w     $0100
  1549.             moveq    #0,d0
  1550.             dc.w     $A82A
  1551.         EndM
  1552.     ELSE
  1553.         IMPORT    SGGetSrcVideoBounds
  1554.     ENDIF
  1555.  
  1556.     IF GENERATING68K THEN
  1557.         Macro
  1558.         _SGSetVideoRect
  1559.             dc.w     $2F3C
  1560.             dc.w     $0004
  1561.             dc.w     $0101
  1562.             moveq    #0,d0
  1563.             dc.w     $A82A
  1564.         EndM
  1565.     ELSE
  1566.         IMPORT    SGSetVideoRect
  1567.     ENDIF
  1568.  
  1569.     IF GENERATING68K THEN
  1570.         Macro
  1571.         _SGGetVideoRect
  1572.             dc.w     $2F3C
  1573.             dc.w     $0004
  1574.             dc.w     $0102
  1575.             moveq    #0,d0
  1576.             dc.w     $A82A
  1577.         EndM
  1578.     ELSE
  1579.         IMPORT    SGGetVideoRect
  1580.     ENDIF
  1581.  
  1582.     IF GENERATING68K THEN
  1583.         Macro
  1584.         _SGGetVideoCompressorType
  1585.             dc.w     $2F3C
  1586.             dc.w     $0004
  1587.             dc.w     $0103
  1588.             moveq    #0,d0
  1589.             dc.w     $A82A
  1590.         EndM
  1591.     ELSE
  1592.         IMPORT    SGGetVideoCompressorType
  1593.     ENDIF
  1594.  
  1595.     IF GENERATING68K THEN
  1596.         Macro
  1597.         _SGSetVideoCompressorType
  1598.             dc.w     $2F3C
  1599.             dc.w     $0004
  1600.             dc.w     $0104
  1601.             moveq    #0,d0
  1602.             dc.w     $A82A
  1603.         EndM
  1604.     ELSE
  1605.         IMPORT    SGSetVideoCompressorType
  1606.     ENDIF
  1607.  
  1608.     IF GENERATING68K THEN
  1609.         Macro
  1610.         _SGSetVideoCompressor
  1611.             dc.w     $2F3C
  1612.             dc.w     $0012
  1613.             dc.w     $0105
  1614.             moveq    #0,d0
  1615.             dc.w     $A82A
  1616.         EndM
  1617.     ELSE
  1618.         IMPORT    SGSetVideoCompressor
  1619.     ENDIF
  1620.  
  1621.     IF GENERATING68K THEN
  1622.         Macro
  1623.         _SGGetVideoCompressor
  1624.             dc.w     $2F3C
  1625.             dc.w     $0014
  1626.             dc.w     $0106
  1627.             moveq    #0,d0
  1628.             dc.w     $A82A
  1629.         EndM
  1630.     ELSE
  1631.         IMPORT    SGGetVideoCompressor
  1632.     ENDIF
  1633.  
  1634.     IF GENERATING68K THEN
  1635.         Macro
  1636.         _SGGetVideoDigitizerComponent
  1637.             dc.w     $2F3C
  1638.             dc.w     $0000
  1639.             dc.w     $0107
  1640.             moveq    #0,d0
  1641.             dc.w     $A82A
  1642.         EndM
  1643.     ELSE
  1644.         IMPORT    SGGetVideoDigitizerComponent
  1645.     ENDIF
  1646.  
  1647.     IF GENERATING68K THEN
  1648.         Macro
  1649.         _SGSetVideoDigitizerComponent
  1650.             dc.w     $2F3C
  1651.             dc.w     $0004
  1652.             dc.w     $0108
  1653.             moveq    #0,d0
  1654.             dc.w     $A82A
  1655.         EndM
  1656.     ELSE
  1657.         IMPORT    SGSetVideoDigitizerComponent
  1658.     ENDIF
  1659.  
  1660.     IF GENERATING68K THEN
  1661.         Macro
  1662.         _SGVideoDigitizerChanged
  1663.             dc.w     $2F3C
  1664.             dc.w     $0000
  1665.             dc.w     $0109
  1666.             moveq    #0,d0
  1667.             dc.w     $A82A
  1668.         EndM
  1669.     ELSE
  1670.         IMPORT    SGVideoDigitizerChanged
  1671.     ENDIF
  1672.  
  1673.     IF GENERATING68K THEN
  1674.         Macro
  1675.         _SGSetVideoBottlenecks
  1676.             dc.w     $2F3C
  1677.             dc.w     $0004
  1678.             dc.w     $010A
  1679.             moveq    #0,d0
  1680.             dc.w     $A82A
  1681.         EndM
  1682.     ELSE
  1683.         IMPORT    SGSetVideoBottlenecks
  1684.     ENDIF
  1685.  
  1686.     IF GENERATING68K THEN
  1687.         Macro
  1688.         _SGGetVideoBottlenecks
  1689.             dc.w     $2F3C
  1690.             dc.w     $0004
  1691.             dc.w     $010B
  1692.             moveq    #0,d0
  1693.             dc.w     $A82A
  1694.         EndM
  1695.     ELSE
  1696.         IMPORT    SGGetVideoBottlenecks
  1697.     ENDIF
  1698.  
  1699.     IF GENERATING68K THEN
  1700.         Macro
  1701.         _SGGrabFrame
  1702.             dc.w     $2F3C
  1703.             dc.w     $0002
  1704.             dc.w     $010C
  1705.             moveq    #0,d0
  1706.             dc.w     $A82A
  1707.         EndM
  1708.     ELSE
  1709.         IMPORT    SGGrabFrame
  1710.     ENDIF
  1711.  
  1712.     IF GENERATING68K THEN
  1713.         Macro
  1714.         _SGGrabFrameComplete
  1715.             dc.w     $2F3C
  1716.             dc.w     $0006
  1717.             dc.w     $010D
  1718.             moveq    #0,d0
  1719.             dc.w     $A82A
  1720.         EndM
  1721.     ELSE
  1722.         IMPORT    SGGrabFrameComplete
  1723.     ENDIF
  1724.  
  1725.     IF GENERATING68K THEN
  1726.         Macro
  1727.         _SGDisplayFrame
  1728.             dc.w     $2F3C
  1729.             dc.w     $000A
  1730.             dc.w     $010E
  1731.             moveq    #0,d0
  1732.             dc.w     $A82A
  1733.         EndM
  1734.     ELSE
  1735.         IMPORT    SGDisplayFrame
  1736.     ENDIF
  1737.  
  1738.     IF GENERATING68K THEN
  1739.         Macro
  1740.         _SGCompressFrame
  1741.             dc.w     $2F3C
  1742.             dc.w     $0002
  1743.             dc.w     $010F
  1744.             moveq    #0,d0
  1745.             dc.w     $A82A
  1746.         EndM
  1747.     ELSE
  1748.         IMPORT    SGCompressFrame
  1749.     ENDIF
  1750.  
  1751.     IF GENERATING68K THEN
  1752.         Macro
  1753.         _SGCompressFrameComplete
  1754.             dc.w     $2F3C
  1755.             dc.w     $000A
  1756.             dc.w     $0110
  1757.             moveq    #0,d0
  1758.             dc.w     $A82A
  1759.         EndM
  1760.     ELSE
  1761.         IMPORT    SGCompressFrameComplete
  1762.     ENDIF
  1763.  
  1764.     IF GENERATING68K THEN
  1765.         Macro
  1766.         _SGAddFrame
  1767.             dc.w     $2F3C
  1768.             dc.w     $000E
  1769.             dc.w     $0111
  1770.             moveq    #0,d0
  1771.             dc.w     $A82A
  1772.         EndM
  1773.     ELSE
  1774.         IMPORT    SGAddFrame
  1775.     ENDIF
  1776.  
  1777.     IF GENERATING68K THEN
  1778.         Macro
  1779.         _SGTransferFrameForCompress
  1780.             dc.w     $2F3C
  1781.             dc.w     $000A
  1782.             dc.w     $0112
  1783.             moveq    #0,d0
  1784.             dc.w     $A82A
  1785.         EndM
  1786.     ELSE
  1787.         IMPORT    SGTransferFrameForCompress
  1788.     ENDIF
  1789.  
  1790.     IF GENERATING68K THEN
  1791.         Macro
  1792.         _SGSetCompressBuffer
  1793.             dc.w     $2F3C
  1794.             dc.w     $0006
  1795.             dc.w     $0113
  1796.             moveq    #0,d0
  1797.             dc.w     $A82A
  1798.         EndM
  1799.     ELSE
  1800.         IMPORT    SGSetCompressBuffer
  1801.     ENDIF
  1802.  
  1803.     IF GENERATING68K THEN
  1804.         Macro
  1805.         _SGGetCompressBuffer
  1806.             dc.w     $2F3C
  1807.             dc.w     $0008
  1808.             dc.w     $0114
  1809.             moveq    #0,d0
  1810.             dc.w     $A82A
  1811.         EndM
  1812.     ELSE
  1813.         IMPORT    SGGetCompressBuffer
  1814.     ENDIF
  1815.  
  1816.     IF GENERATING68K THEN
  1817.         Macro
  1818.         _SGGetBufferInfo
  1819.             dc.w     $2F3C
  1820.             dc.w     $0012
  1821.             dc.w     $0115
  1822.             moveq    #0,d0
  1823.             dc.w     $A82A
  1824.         EndM
  1825.     ELSE
  1826.         IMPORT    SGGetBufferInfo
  1827.     ENDIF
  1828.  
  1829.     IF GENERATING68K THEN
  1830.         Macro
  1831.         _SGSetUseScreenBuffer
  1832.             dc.w     $2F3C
  1833.             dc.w     $0002
  1834.             dc.w     $0116
  1835.             moveq    #0,d0
  1836.             dc.w     $A82A
  1837.         EndM
  1838.     ELSE
  1839.         IMPORT    SGSetUseScreenBuffer
  1840.     ENDIF
  1841.  
  1842.     IF GENERATING68K THEN
  1843.         Macro
  1844.         _SGGetUseScreenBuffer
  1845.             dc.w     $2F3C
  1846.             dc.w     $0004
  1847.             dc.w     $0117
  1848.             moveq    #0,d0
  1849.             dc.w     $A82A
  1850.         EndM
  1851.     ELSE
  1852.         IMPORT    SGGetUseScreenBuffer
  1853.     ENDIF
  1854.  
  1855.     IF GENERATING68K THEN
  1856.         Macro
  1857.         _SGGrabCompressComplete
  1858.             dc.w     $2F3C
  1859.             dc.w     $000C
  1860.             dc.w     $0118
  1861.             moveq    #0,d0
  1862.             dc.w     $A82A
  1863.         EndM
  1864.     ELSE
  1865.         IMPORT    SGGrabCompressComplete
  1866.     ENDIF
  1867.  
  1868.     IF GENERATING68K THEN
  1869.         Macro
  1870.         _SGDisplayCompress
  1871.             dc.w     $2F3C
  1872.             dc.w     $0010
  1873.             dc.w     $0119
  1874.             moveq    #0,d0
  1875.             dc.w     $A82A
  1876.         EndM
  1877.     ELSE
  1878.         IMPORT    SGDisplayCompress
  1879.     ENDIF
  1880.  
  1881.     IF GENERATING68K THEN
  1882.         Macro
  1883.         _SGSetFrameRate
  1884.             dc.w     $2F3C
  1885.             dc.w     $0004
  1886.             dc.w     $011A
  1887.             moveq    #0,d0
  1888.             dc.w     $A82A
  1889.         EndM
  1890.     ELSE
  1891.         IMPORT    SGSetFrameRate
  1892.     ENDIF
  1893.  
  1894.     IF GENERATING68K THEN
  1895.         Macro
  1896.         _SGGetFrameRate
  1897.             dc.w     $2F3C
  1898.             dc.w     $0004
  1899.             dc.w     $011B
  1900.             moveq    #0,d0
  1901.             dc.w     $A82A
  1902.         EndM
  1903.     ELSE
  1904.         IMPORT    SGGetFrameRate
  1905.     ENDIF
  1906.  
  1907. ;** Sequence Grab SOUND CHANNEL Component Stuff **
  1908. ;
  1909. ;    Sound stuff
  1910. ;
  1911.     IF GENERATING68K THEN
  1912.         Macro
  1913.         _SGSetSoundInputDriver
  1914.             dc.w     $2F3C
  1915.             dc.w     $0004
  1916.             dc.w     $0100
  1917.             moveq    #0,d0
  1918.             dc.w     $A82A
  1919.         EndM
  1920.     ELSE
  1921.         IMPORT    SGSetSoundInputDriver
  1922.     ENDIF
  1923.  
  1924.     IF GENERATING68K THEN
  1925.         Macro
  1926.         _SGGetSoundInputDriver
  1927.             dc.w     $2F3C
  1928.             dc.w     $0000
  1929.             dc.w     $0101
  1930.             moveq    #0,d0
  1931.             dc.w     $A82A
  1932.         EndM
  1933.     ELSE
  1934.         IMPORT    SGGetSoundInputDriver
  1935.     ENDIF
  1936.  
  1937.     IF GENERATING68K THEN
  1938.         Macro
  1939.         _SGSoundInputDriverChanged
  1940.             dc.w     $2F3C
  1941.             dc.w     $0000
  1942.             dc.w     $0102
  1943.             moveq    #0,d0
  1944.             dc.w     $A82A
  1945.         EndM
  1946.     ELSE
  1947.         IMPORT    SGSoundInputDriverChanged
  1948.     ENDIF
  1949.  
  1950.     IF GENERATING68K THEN
  1951.         Macro
  1952.         _SGSetSoundRecordChunkSize
  1953.             dc.w     $2F3C
  1954.             dc.w     $0004
  1955.             dc.w     $0103
  1956.             moveq    #0,d0
  1957.             dc.w     $A82A
  1958.         EndM
  1959.     ELSE
  1960.         IMPORT    SGSetSoundRecordChunkSize
  1961.     ENDIF
  1962.  
  1963.     IF GENERATING68K THEN
  1964.         Macro
  1965.         _SGGetSoundRecordChunkSize
  1966.             dc.w     $2F3C
  1967.             dc.w     $0000
  1968.             dc.w     $0104
  1969.             moveq    #0,d0
  1970.             dc.w     $A82A
  1971.         EndM
  1972.     ELSE
  1973.         IMPORT    SGGetSoundRecordChunkSize
  1974.     ENDIF
  1975.  
  1976.     IF GENERATING68K THEN
  1977.         Macro
  1978.         _SGSetSoundInputRate
  1979.             dc.w     $2F3C
  1980.             dc.w     $0004
  1981.             dc.w     $0105
  1982.             moveq    #0,d0
  1983.             dc.w     $A82A
  1984.         EndM
  1985.     ELSE
  1986.         IMPORT    SGSetSoundInputRate
  1987.     ENDIF
  1988.  
  1989.     IF GENERATING68K THEN
  1990.         Macro
  1991.         _SGGetSoundInputRate
  1992.             dc.w     $2F3C
  1993.             dc.w     $0000
  1994.             dc.w     $0106
  1995.             moveq    #0,d0
  1996.             dc.w     $A82A
  1997.         EndM
  1998.     ELSE
  1999.         IMPORT    SGGetSoundInputRate
  2000.     ENDIF
  2001.  
  2002.     IF GENERATING68K THEN
  2003.         Macro
  2004.         _SGSetSoundInputParameters
  2005.             dc.w     $2F3C
  2006.             dc.w     $0008
  2007.             dc.w     $0107
  2008.             moveq    #0,d0
  2009.             dc.w     $A82A
  2010.         EndM
  2011.     ELSE
  2012.         IMPORT    SGSetSoundInputParameters
  2013.     ENDIF
  2014.  
  2015.     IF GENERATING68K THEN
  2016.         Macro
  2017.         _SGGetSoundInputParameters
  2018.             dc.w     $2F3C
  2019.             dc.w     $000C
  2020.             dc.w     $0108
  2021.             moveq    #0,d0
  2022.             dc.w     $A82A
  2023.         EndM
  2024.     ELSE
  2025.         IMPORT    SGGetSoundInputParameters
  2026.     ENDIF
  2027.  
  2028.  
  2029. sgChannelAtom                    EQU        'chan'
  2030. sgChannelSettingsAtom            EQU        'ctom'
  2031. sgChannelDescription            EQU        'cdsc'
  2032. sgChannelSettings                EQU        'cset'
  2033.  
  2034. sgDeviceNameType                EQU        'name'
  2035. sgUsageType                        EQU        'use '
  2036. sgPlayFlagsType                    EQU        'plyf'
  2037. sgClipType                        EQU        'clip'
  2038. sgMatrixType                    EQU        'mtrx'
  2039. sgVolumeType                    EQU        'volu'
  2040.  
  2041. sgPanelSettingsAtom                EQU        'ptom'
  2042. sgPanelDescription                EQU        'pdsc'
  2043. sgPanelSettings                    EQU        'pset'
  2044.  
  2045. sgcSoundCompressionType            EQU        'scmp'
  2046. sgcSoundSampleRateType            EQU        'srat'
  2047. sgcSoundChannelCountType        EQU        'schn'
  2048. sgcSoundSampleSizeType            EQU        'ssiz'
  2049. sgcSoundInputType                EQU        'sinp'
  2050. sgcSoundGainType                EQU        'gain'
  2051.  
  2052. sgcVideoHueType                    EQU        'hue '
  2053. sgcVideoSaturationType            EQU        'satr'
  2054. sgcVideoContrastType            EQU        'trst'
  2055. sgcVideoSharpnessType            EQU        'shrp'
  2056. sgcVideoBrigtnessType            EQU        'brit'
  2057. sgcVideoBlackLevelType            EQU        'blkl'
  2058. sgcVideoWhiteLevelType            EQU        'whtl'
  2059. sgcVideoInputType                EQU        'vinp'
  2060. sgcVideoFormatType                EQU        'vstd'
  2061. sgcVideoFilterType                EQU        'vflt'
  2062. sgcVideoRectType                EQU        'vrct'
  2063. sgVideoDigitizerType            EQU        'vdig'
  2064.  
  2065. kSGInitializeSelect                EQU        $1
  2066. kSGSetDataOutputSelect            EQU        $2
  2067. kSGGetDataOutputSelect            EQU        $3
  2068. kSGSetGWorldSelect                EQU        $4
  2069. kSGGetGWorldSelect                EQU        $5
  2070. kSGNewChannelSelect                EQU        $6
  2071. kSGDisposeChannelSelect            EQU        $7
  2072. kSGStartPreviewSelect            EQU        $10
  2073. kSGStartRecordSelect            EQU        $11
  2074. kSGIdleSelect                    EQU        $12
  2075. kSGStopSelect                    EQU        $13
  2076. kSGPauseSelect                    EQU        $14
  2077. kSGPrepareSelect                EQU        $15
  2078. kSGReleaseSelect                EQU        $16
  2079. kSGGetMovieSelect                EQU        $17
  2080. kSGSetMaximumRecordTimeSelect    EQU        $18
  2081. kSGGetMaximumRecordTimeSelect    EQU        $19
  2082. kSGGetStorageSpaceRemainingSelect EQU        $1A
  2083. kSGGetTimeRemainingSelect        EQU        $1B
  2084. kSGGrabPictSelect                EQU        $1C
  2085. kSGGetLastMovieResIDSelect        EQU        $1D
  2086. kSGSetFlagsSelect                EQU        $1E
  2087. kSGGetFlagsSelect                EQU        $1F
  2088. kSGSetDataProcSelect            EQU        $20
  2089. kSGNewChannelFromComponentSelect EQU        $21
  2090. kSGDisposeDeviceListSelect        EQU        $22
  2091. kSGAppendDeviceListToMenuSelect    EQU        $23
  2092. kSGSetSettingsSelect            EQU        $24
  2093. kSGGetSettingsSelect            EQU        $25
  2094. kSGGetIndChannelSelect            EQU        $26
  2095. kSGUpdateSelect                    EQU        $27
  2096. kSGGetPauseSelect                EQU        $28
  2097. kSGSettingsDialogSelect            EQU        $29
  2098. kSGGetAlignmentProcSelect        EQU        $2A
  2099. kSGSetChannelSettingsSelect        EQU        $2B
  2100. kSGGetChannelSettingsSelect        EQU        $2C
  2101. kSGGetModeSelect                EQU        $2D
  2102. kSGSetDataRefSelect                EQU        $2E
  2103. kSGGetDataRefSelect                EQU        $2F
  2104. kSGNewOutputSelect                EQU        $30
  2105. kSGDisposeOutputSelect            EQU        $31
  2106. kSGSetOutputFlagsSelect            EQU        $32
  2107. kSGSetChannelOutputSelect        EQU        $33
  2108. kSGGetDataOutputStorageSpaceRemainingSelect EQU        $34
  2109. kSGWriteMovieDataSelect            EQU        $100
  2110. kSGAddFrameReferenceSelect        EQU        $101
  2111. kSGGetNextFrameReferenceSelect    EQU        $102
  2112. kSGGetTimeBaseSelect            EQU        $103
  2113. kSGSortDeviceListSelect            EQU        $104
  2114. kSGAddMovieDataSelect            EQU        $105
  2115. kSGChangedSourceSelect            EQU        $106
  2116. kSGCSetChannelUsageSelect        EQU        $80
  2117. kSGCGetChannelUsageSelect        EQU        $81
  2118. kSGCSetChannelBoundsSelect        EQU        $82
  2119. kSGCGetChannelBoundsSelect        EQU        $83
  2120. kSGCSetChannelVolumeSelect        EQU        $84
  2121. kSGCGetChannelVolumeSelect        EQU        $85
  2122. kSGCGetChannelInfoSelect        EQU        $86
  2123. kSGCSetChannelPlayFlagsSelect    EQU        $87
  2124. kSGCGetChannelPlayFlagsSelect    EQU        $88
  2125. kSGCSetChannelMaxFramesSelect    EQU        $89
  2126. kSGCGetChannelMaxFramesSelect    EQU        $8A
  2127. kSGCSetChannelRefConSelect        EQU        $8B
  2128. kSGCSetChannelClipSelect        EQU        $8C
  2129. kSGCGetChannelClipSelect        EQU        $8D
  2130. kSGCGetChannelSampleDescriptionSelect EQU        $8E
  2131. kSGCGetChannelDeviceListSelect    EQU        $8F
  2132. kSGCSetChannelDeviceSelect        EQU        $90
  2133. kSGCSetChannelMatrixSelect        EQU        $91
  2134. kSGCGetChannelMatrixSelect        EQU        $92
  2135. kSGCGetChannelTimeScaleSelect    EQU        $93
  2136. kSGCChannelPutPictureSelect        EQU        $94
  2137. kSGCChannelSetRequestedDataRateSelect EQU        $95
  2138. kSGCChannelGetRequestedDataRateSelect EQU        $96
  2139. kSGCChannelSetDataSourceNameSelect EQU        $97
  2140. kSGCChannelGetDataSourceNameSelect EQU        $98
  2141. kSGCInitChannelSelect            EQU        $180
  2142. kSGCWriteSamplesSelect            EQU        $181
  2143. kSGCGetDataRateSelect            EQU        $182
  2144. kSGCAlignChannelRectSelect        EQU        $183
  2145. kSGCPanelGetDitlSelect            EQU        $200
  2146. kSGCPanelGetTitleSelect            EQU        $201
  2147. kSGCPanelCanRunSelect            EQU        $202
  2148. kSGCPanelInstallSelect            EQU        $203
  2149. kSGCPanelEventSelect            EQU        $204
  2150. kSGCPanelItemSelect                EQU        $205
  2151. kSGCPanelRemoveSelect            EQU        $206
  2152. kSGCPanelSetGrabberSelect        EQU        $207
  2153. kSGCPanelSetResFileSelect        EQU        $208
  2154. kSGCPanelGetSettingsSelect        EQU        $209
  2155. kSGCPanelSetSettingsSelect        EQU        $20A
  2156. kSGCPanelValidateInputSelect    EQU        $20B
  2157. kSGCPanelSetEventFilterSelect    EQU        $20C
  2158. kSGCGetSrcVideoBoundsSelect        EQU        $100
  2159. kSGCSetVideoRectSelect            EQU        $101
  2160. kSGCGetVideoRectSelect            EQU        $102
  2161. kSGCGetVideoCompressorTypeSelect EQU        $103
  2162. kSGCSetVideoCompressorTypeSelect EQU        $104
  2163. kSGCSetVideoCompressorSelect    EQU        $105
  2164. kSGCGetVideoCompressorSelect    EQU        $106
  2165. kSGCGetVideoDigitizerComponentSelect EQU        $107
  2166. kSGCSetVideoDigitizerComponentSelect EQU        $108
  2167. kSGCVideoDigitizerChangedSelect    EQU        $109
  2168. kSGCSetVideoBottlenecksSelect    EQU        $10A
  2169. kSGCGetVideoBottlenecksSelect    EQU        $10B
  2170. kSGCGrabFrameSelect                EQU        $10C
  2171. kSGCGrabFrameCompleteSelect        EQU        $10D
  2172. kSGCDisplayFrameSelect            EQU        $10E
  2173. kSGCCompressFrameSelect            EQU        $10F
  2174. kSGCCompressFrameCompleteSelect    EQU        $110
  2175. kSGCAddFrameSelect                EQU        $111
  2176. kSGCTransferFrameForCompressSelect EQU        $112
  2177. kSGCSetCompressBufferSelect        EQU        $113
  2178. kSGCGetCompressBufferSelect        EQU        $114
  2179. kSGCGetBufferInfoSelect            EQU        $115
  2180. kSGCSetUseScreenBufferSelect    EQU        $116
  2181. kSGCGetUseScreenBufferSelect    EQU        $117
  2182. kSGCGrabCompressCompleteSelect    EQU        $118
  2183. kSGCDisplayCompressSelect        EQU        $119
  2184. kSGCSetFrameRateSelect            EQU        $11A
  2185. kSGCGetFrameRateSelect            EQU        $11B
  2186. kSGCSetSoundInputDriverSelect    EQU        $100
  2187. kSGCGetSoundInputDriverSelect    EQU        $101
  2188. kSGCSoundInputDriverChangedSelect EQU        $102
  2189. kSGCSetSoundRecordChunkSizeSelect EQU        $103
  2190. kSGCGetSoundRecordChunkSizeSelect EQU        $104
  2191. kSGCSetSoundInputRateSelect        EQU        $105
  2192. kSGCGetSoundInputRateSelect        EQU        $106
  2193. kSGCSetSoundInputParametersSelect EQU        $107
  2194. kSGCGetSoundInputParametersSelect EQU        $108
  2195.  
  2196. ; Standard type for video digitizers 
  2197. videoDigitizerComponentType        EQU        'vdig'
  2198. vdigInterfaceRev                EQU        2
  2199.  
  2200. ; Input Format Standards 
  2201. ntscIn                            EQU        0                    ; current input format 
  2202. currentIn                        EQU        0                    ; ntsc input format 
  2203. palIn                            EQU        1                    ; pal input format 
  2204. secamIn                            EQU        2                    ; secam input format 
  2205. ntscReallyIn                    EQU        3                    ; ntsc input format 
  2206.  
  2207. ; Input Formats 
  2208. compositeIn                        EQU        0                    ; input is composite format 
  2209. sVideoIn                        EQU        1                    ; input is sVideo format 
  2210. rgbComponentIn                    EQU        2                    ; input is rgb component format 
  2211. rgbComponentSyncIn                EQU        3                    ; input is rgb component format (sync on green?)
  2212. yuvComponentIn                    EQU        4                    ; input is yuv component format 
  2213. yuvComponentSyncIn                EQU        5                    ; input is yuv component format (sync on green?) 
  2214.  
  2215. ; Video Digitizer PlayThru States 
  2216. vdPlayThruOff                    EQU        0
  2217. vdPlayThruOn                    EQU        1
  2218.  
  2219. ; Input Color Space Modes 
  2220. vdDigitizerBW                    EQU        0                    ; black and white 
  2221. vdDigitizerRGB                    EQU        1                    ; rgb color 
  2222.  
  2223. ; Phase Lock Loop Modes 
  2224. vdBroadcastMode                    EQU        0                    ; Broadcast / Laser Disk video mode 
  2225. vdVTRMode                        EQU        1                    ; VCR / Magnetic media mode 
  2226.  
  2227. ; Field Select Options 
  2228. vdUseAnyField                    EQU        0                    ; Digitizers choice on field use 
  2229. vdUseOddField                    EQU        1                    ; Use odd field for half size vert and smaller 
  2230. vdUseEvenField                    EQU        2                    ; Use even field for half size vert and smaller 
  2231.  
  2232. ; vdig types 
  2233. vdTypeBasic                        EQU        0                    ; basic, no clipping 
  2234. vdTypeAlpha                        EQU        1                    ; supports clipping with alpha channel 
  2235. vdTypeMask                        EQU        2                    ; supports clipping with mask plane 
  2236. vdTypeKey                        EQU        3                    ; supports clipping with key color(s) 
  2237.  
  2238. ; Digitizer Input Capability/Current Flags    
  2239. digiInDoesNTSC                    EQU        1 << 0                ; digitizer supports NTSC input format 
  2240. digiInDoesPAL                    EQU        1 << 1                ; digitizer supports PAL input format 
  2241. digiInDoesSECAM                    EQU        1 << 2                ; digitizer supports SECAM input format 
  2242. digiInDoesGenLock                EQU        1 << 7                ; digitizer does genlock 
  2243. digiInDoesComposite                EQU        1 << 8                ; digitizer supports composite input type 
  2244. digiInDoesSVideo                EQU        1 << 9                ; digitizer supports S-Video input type 
  2245. digiInDoesComponent                EQU        1 << 10                ; digitizer supports component = rgb, input type 
  2246. digiInVTR_Broadcast                EQU        1 << 11                ; digitizer can differentiate between the two 
  2247. digiInDoesColor                    EQU        1 << 12                ; digitizer supports color 
  2248. digiInDoesBW                    EQU        1 << 13                ; digitizer supports black & white 
  2249. ; Digitizer Input Current Flags = these are valid only during active operating conditions,    
  2250. digiInSignalLock                EQU        1 << 31                ; digitizer detects input signal is locked, this bit = horiz lock || vertical lock 
  2251.  
  2252. ; Digitizer Output Capability/Current Flags 
  2253. digiOutDoes1                    EQU        1 << 0                ; digitizer supports 1 bit pixels 
  2254. digiOutDoes2                    EQU        1 << 1                ; digitizer supports 2 bit pixels 
  2255. digiOutDoes4                    EQU        1 << 2                ; digitizer supports 4 bit pixels 
  2256. digiOutDoes8                    EQU        1 << 3                ; digitizer supports 8 bit pixels 
  2257. digiOutDoes16                    EQU        1 << 4                ; digitizer supports 16 bit pixels 
  2258. digiOutDoes32                    EQU        1 << 5                ; digitizer supports 32 bit pixels 
  2259. digiOutDoesDither                EQU        1 << 6                ; digitizer dithers in indexed modes 
  2260. digiOutDoesStretch                EQU        1 << 7                ; digitizer can arbitrarily stretch 
  2261. digiOutDoesShrink                EQU        1 << 8                ; digitizer can arbitrarily shrink 
  2262. digiOutDoesMask                    EQU        1 << 9                ; digitizer can mask to clipping regions 
  2263. digiOutDoesDouble                EQU        1 << 11                ; digitizer can stretch to exactly double size 
  2264. digiOutDoesQuad                    EQU        1 << 12                ; digitizer can stretch exactly quadruple size 
  2265. digiOutDoesQuarter                EQU        1 << 13                ; digitizer can shrink to exactly quarter size 
  2266. digiOutDoesSixteenth            EQU        1 << 14                ; digitizer can shrink to exactly sixteenth size 
  2267. digiOutDoesRotate                EQU        1 << 15                ; digitizer supports rotate transformations 
  2268. digiOutDoesHorizFlip            EQU        1 << 16                ; digitizer supports horizontal flips Sx < 0 
  2269. digiOutDoesVertFlip                EQU        1 << 17                ; digitizer supports vertical flips Sy < 0 
  2270. digiOutDoesSkew                    EQU        1 << 18                ; digitizer supports skew = shear,twist, 
  2271. digiOutDoesBlend                EQU        1 << 19
  2272. digiOutDoesWarp                    EQU        1 << 20
  2273. digiOutDoesHW_DMA                EQU        1 << 21                ; digitizer not constrained to local device 
  2274. digiOutDoesHWPlayThru            EQU        1 << 22                ; digitizer doesn't need time to play thru 
  2275. digiOutDoesILUT                    EQU        1 << 23                ; digitizer does inverse LUT for index modes 
  2276. digiOutDoesKeyColor                EQU        1 << 24                ; digitizer does key color functions too 
  2277. digiOutDoesAsyncGrabs            EQU        1 << 25                ; digitizer supports async grabs 
  2278. digiOutDoesUnreadableScreenBits    EQU        1 << 26                ; playthru doesn't generate readable bits on screen
  2279. digiOutDoesCompress                EQU        1 << 27                ; supports alternate output data types 
  2280. digiOutDoesCompressOnly            EQU        1 << 28                ; can't provide raw frames anywhere 
  2281. digiOutDoesPlayThruDuringCompress EQU        1 << 29            ; digi can do playthru while providing compressed data 
  2282.  
  2283. ; Types 
  2284. DigitizerInfo             RECORD    0
  2285. vdigType                 ds.w    1
  2286. inputCapabilityFlags     ds.l    1
  2287. outputCapabilityFlags     ds.l    1
  2288. inputCurrentFlags         ds.l    1
  2289. outputCurrentFlags         ds.l    1
  2290. slot                     ds.w    1                                    ; temporary for connection purposes 
  2291. gdh                         ds.l    1                                    ; temporary for digitizers that have preferred screen 
  2292. maskgdh                     ds.l    1                                    ; temporary for digitizers that have mask planes 
  2293. minDestHeight             ds.w    1                                    ; Smallest resizable height 
  2294. minDestWidth             ds.w    1                                    ; Smallest resizable width 
  2295. maxDestHeight             ds.w    1                                    ; Largest resizable height 
  2296. maxDestWidth             ds.w    1                                    ; Largest resizable height 
  2297. blendLevels                 ds.w    1                                    ; Number of blend levels supported (2 if 1 bit mask) 
  2298. reserved                 ds.l    1                                    ; reserved 
  2299. sizeof                     EQU    42
  2300.                         ENDR
  2301.  
  2302. VdigType                 RECORD    0
  2303. digType                     ds.l    1
  2304. reserved                 ds.l    1
  2305. sizeof                     EQU    8
  2306.                         ENDR
  2307.  
  2308. VdigTypeList             RECORD    0
  2309. count                     ds.w    1
  2310. list                     ds        VdigType
  2311. sizeof                     EQU    10
  2312.                         ENDR
  2313.  
  2314. VdigBufferRec             RECORD    0
  2315. dest                     ds.l    1
  2316. location                 ds        Point
  2317. reserved                 ds.l    1
  2318. sizeof                     EQU    12
  2319.                         ENDR
  2320.  
  2321. VdigBufferRecList         RECORD    0
  2322. count                     ds.w    1
  2323. matrix                     ds.l    1
  2324. mask                     ds.l    1
  2325. list                     ds        VdigBufferRec
  2326. sizeof                     EQU    22
  2327.                         ENDR
  2328.  
  2329. VDCompressionList         RECORD    0
  2330. codec                     ds.l    1
  2331. cType                     ds.l    1
  2332. typeName                 ds.l    16
  2333. name                     ds.l    16
  2334. formatFlags                 ds.l    1
  2335. compressFlags             ds.l    1
  2336. reserved                 ds.l    1
  2337. sizeof                     EQU    148
  2338.                         ENDR
  2339.  
  2340.  
  2341. dmaDepth1                        EQU        1
  2342. dmaDepth2                        EQU        2
  2343. dmaDepth4                        EQU        4
  2344. dmaDepth8                        EQU        8
  2345. dmaDepth16                        EQU        16
  2346. dmaDepth32                        EQU        32
  2347. dmaDepth2Gray                    EQU        64
  2348. dmaDepth4Gray                    EQU        128
  2349. dmaDepth8Gray                    EQU        256
  2350.  
  2351. kVDIGControlledFrameRate        EQU        -1
  2352.  
  2353. ; number of vdig calls
  2354. kvdigSelectors                    EQU        86
  2355.  
  2356.     IF GENERATING68K THEN
  2357.         Macro
  2358.         _VDGetMaxSrcRect
  2359.             dc.w     $2F3C
  2360.             dc.w     $0006
  2361.             dc.w     $0001
  2362.             moveq    #0,d0
  2363.             dc.w     $A82A
  2364.         EndM
  2365.     ELSE
  2366.         IMPORT    VDGetMaxSrcRect
  2367.     ENDIF
  2368.  
  2369.     IF GENERATING68K THEN
  2370.         Macro
  2371.         _VDGetActiveSrcRect
  2372.             dc.w     $2F3C
  2373.             dc.w     $0006
  2374.             dc.w     $0002
  2375.             moveq    #0,d0
  2376.             dc.w     $A82A
  2377.         EndM
  2378.     ELSE
  2379.         IMPORT    VDGetActiveSrcRect
  2380.     ENDIF
  2381.  
  2382.     IF GENERATING68K THEN
  2383.         Macro
  2384.         _VDSetDigitizerRect
  2385.             dc.w     $2F3C
  2386.             dc.w     $0004
  2387.             dc.w     $0003
  2388.             moveq    #0,d0
  2389.             dc.w     $A82A
  2390.         EndM
  2391.     ELSE
  2392.         IMPORT    VDSetDigitizerRect
  2393.     ENDIF
  2394.  
  2395.     IF GENERATING68K THEN
  2396.         Macro
  2397.         _VDGetDigitizerRect
  2398.             dc.w     $2F3C
  2399.             dc.w     $0004
  2400.             dc.w     $0004
  2401.             moveq    #0,d0
  2402.             dc.w     $A82A
  2403.         EndM
  2404.     ELSE
  2405.         IMPORT    VDGetDigitizerRect
  2406.     ENDIF
  2407.  
  2408.     IF GENERATING68K THEN
  2409.         Macro
  2410.         _VDGetVBlankRect
  2411.             dc.w     $2F3C
  2412.             dc.w     $0006
  2413.             dc.w     $0005
  2414.             moveq    #0,d0
  2415.             dc.w     $A82A
  2416.         EndM
  2417.     ELSE
  2418.         IMPORT    VDGetVBlankRect
  2419.     ENDIF
  2420.  
  2421.     IF GENERATING68K THEN
  2422.         Macro
  2423.         _VDGetMaskPixMap
  2424.             dc.w     $2F3C
  2425.             dc.w     $0004
  2426.             dc.w     $0006
  2427.             moveq    #0,d0
  2428.             dc.w     $A82A
  2429.         EndM
  2430.     ELSE
  2431.         IMPORT    VDGetMaskPixMap
  2432.     ENDIF
  2433.  
  2434.     IF GENERATING68K THEN
  2435.         Macro
  2436.         _VDGetPlayThruDestination
  2437.             dc.w     $2F3C
  2438.             dc.w     $0010
  2439.             dc.w     $0008
  2440.             moveq    #0,d0
  2441.             dc.w     $A82A
  2442.         EndM
  2443.     ELSE
  2444.         IMPORT    VDGetPlayThruDestination
  2445.     ENDIF
  2446.  
  2447.     IF GENERATING68K THEN
  2448.         Macro
  2449.         _VDUseThisCLUT
  2450.             dc.w     $2F3C
  2451.             dc.w     $0004
  2452.             dc.w     $0009
  2453.             moveq    #0,d0
  2454.             dc.w     $A82A
  2455.         EndM
  2456.     ELSE
  2457.         IMPORT    VDUseThisCLUT
  2458.     ENDIF
  2459.  
  2460.     IF GENERATING68K THEN
  2461.         Macro
  2462.         _VDSetInputGammaValue
  2463.             dc.w     $2F3C
  2464.             dc.w     $000C
  2465.             dc.w     $000A
  2466.             moveq    #0,d0
  2467.             dc.w     $A82A
  2468.         EndM
  2469.     ELSE
  2470.         IMPORT    VDSetInputGammaValue
  2471.     ENDIF
  2472.  
  2473.     IF GENERATING68K THEN
  2474.         Macro
  2475.         _VDGetInputGammaValue
  2476.             dc.w     $2F3C
  2477.             dc.w     $000C
  2478.             dc.w     $000B
  2479.             moveq    #0,d0
  2480.             dc.w     $A82A
  2481.         EndM
  2482.     ELSE
  2483.         IMPORT    VDGetInputGammaValue
  2484.     ENDIF
  2485.  
  2486.     IF GENERATING68K THEN
  2487.         Macro
  2488.         _VDSetBrightness
  2489.             dc.w     $2F3C
  2490.             dc.w     $0004
  2491.             dc.w     $000C
  2492.             moveq    #0,d0
  2493.             dc.w     $A82A
  2494.         EndM
  2495.     ELSE
  2496.         IMPORT    VDSetBrightness
  2497.     ENDIF
  2498.  
  2499.     IF GENERATING68K THEN
  2500.         Macro
  2501.         _VDGetBrightness
  2502.             dc.w     $2F3C
  2503.             dc.w     $0004
  2504.             dc.w     $000D
  2505.             moveq    #0,d0
  2506.             dc.w     $A82A
  2507.         EndM
  2508.     ELSE
  2509.         IMPORT    VDGetBrightness
  2510.     ENDIF
  2511.  
  2512.     IF GENERATING68K THEN
  2513.         Macro
  2514.         _VDSetContrast
  2515.             dc.w     $2F3C
  2516.             dc.w     $0004
  2517.             dc.w     $000E
  2518.             moveq    #0,d0
  2519.             dc.w     $A82A
  2520.         EndM
  2521.     ELSE
  2522.         IMPORT    VDSetContrast
  2523.     ENDIF
  2524.  
  2525.     IF GENERATING68K THEN
  2526.         Macro
  2527.         _VDSetHue
  2528.             dc.w     $2F3C
  2529.             dc.w     $0004
  2530.             dc.w     $000F
  2531.             moveq    #0,d0
  2532.             dc.w     $A82A
  2533.         EndM
  2534.     ELSE
  2535.         IMPORT    VDSetHue
  2536.     ENDIF
  2537.  
  2538.     IF GENERATING68K THEN
  2539.         Macro
  2540.         _VDSetSharpness
  2541.             dc.w     $2F3C
  2542.             dc.w     $0004
  2543.             dc.w     $0010
  2544.             moveq    #0,d0
  2545.             dc.w     $A82A
  2546.         EndM
  2547.     ELSE
  2548.         IMPORT    VDSetSharpness
  2549.     ENDIF
  2550.  
  2551.     IF GENERATING68K THEN
  2552.         Macro
  2553.         _VDSetSaturation
  2554.             dc.w     $2F3C
  2555.             dc.w     $0004
  2556.             dc.w     $0011
  2557.             moveq    #0,d0
  2558.             dc.w     $A82A
  2559.         EndM
  2560.     ELSE
  2561.         IMPORT    VDSetSaturation
  2562.     ENDIF
  2563.  
  2564.     IF GENERATING68K THEN
  2565.         Macro
  2566.         _VDGetContrast
  2567.             dc.w     $2F3C
  2568.             dc.w     $0004
  2569.             dc.w     $0012
  2570.             moveq    #0,d0
  2571.             dc.w     $A82A
  2572.         EndM
  2573.     ELSE
  2574.         IMPORT    VDGetContrast
  2575.     ENDIF
  2576.  
  2577.     IF GENERATING68K THEN
  2578.         Macro
  2579.         _VDGetHue
  2580.             dc.w     $2F3C
  2581.             dc.w     $0004
  2582.             dc.w     $0013
  2583.             moveq    #0,d0
  2584.             dc.w     $A82A
  2585.         EndM
  2586.     ELSE
  2587.         IMPORT    VDGetHue
  2588.     ENDIF
  2589.  
  2590.     IF GENERATING68K THEN
  2591.         Macro
  2592.         _VDGetSharpness
  2593.             dc.w     $2F3C
  2594.             dc.w     $0004
  2595.             dc.w     $0014
  2596.             moveq    #0,d0
  2597.             dc.w     $A82A
  2598.         EndM
  2599.     ELSE
  2600.         IMPORT    VDGetSharpness
  2601.     ENDIF
  2602.  
  2603.     IF GENERATING68K THEN
  2604.         Macro
  2605.         _VDGetSaturation
  2606.             dc.w     $2F3C
  2607.             dc.w     $0004
  2608.             dc.w     $0015
  2609.             moveq    #0,d0
  2610.             dc.w     $A82A
  2611.         EndM
  2612.     ELSE
  2613.         IMPORT    VDGetSaturation
  2614.     ENDIF
  2615.  
  2616.     IF GENERATING68K THEN
  2617.         Macro
  2618.         _VDGrabOneFrame
  2619.             dc.w     $2F3C
  2620.             dc.w     $0000
  2621.             dc.w     $0016
  2622.             moveq    #0,d0
  2623.             dc.w     $A82A
  2624.         EndM
  2625.     ELSE
  2626.         IMPORT    VDGrabOneFrame
  2627.     ENDIF
  2628.  
  2629.     IF GENERATING68K THEN
  2630.         Macro
  2631.         _VDGetMaxAuxBuffer
  2632.             dc.w     $2F3C
  2633.             dc.w     $0008
  2634.             dc.w     $0017
  2635.             moveq    #0,d0
  2636.             dc.w     $A82A
  2637.         EndM
  2638.     ELSE
  2639.         IMPORT    VDGetMaxAuxBuffer
  2640.     ENDIF
  2641.  
  2642.     IF GENERATING68K THEN
  2643.         Macro
  2644.         _VDGetDigitizerInfo
  2645.             dc.w     $2F3C
  2646.             dc.w     $0004
  2647.             dc.w     $0019
  2648.             moveq    #0,d0
  2649.             dc.w     $A82A
  2650.         EndM
  2651.     ELSE
  2652.         IMPORT    VDGetDigitizerInfo
  2653.     ENDIF
  2654.  
  2655.     IF GENERATING68K THEN
  2656.         Macro
  2657.         _VDGetCurrentFlags
  2658.             dc.w     $2F3C
  2659.             dc.w     $0008
  2660.             dc.w     $001A
  2661.             moveq    #0,d0
  2662.             dc.w     $A82A
  2663.         EndM
  2664.     ELSE
  2665.         IMPORT    VDGetCurrentFlags
  2666.     ENDIF
  2667.  
  2668.     IF GENERATING68K THEN
  2669.         Macro
  2670.         _VDSetKeyColor
  2671.             dc.w     $2F3C
  2672.             dc.w     $0004
  2673.             dc.w     $001B
  2674.             moveq    #0,d0
  2675.             dc.w     $A82A
  2676.         EndM
  2677.     ELSE
  2678.         IMPORT    VDSetKeyColor
  2679.     ENDIF
  2680.  
  2681.     IF GENERATING68K THEN
  2682.         Macro
  2683.         _VDGetKeyColor
  2684.             dc.w     $2F3C
  2685.             dc.w     $0004
  2686.             dc.w     $001C
  2687.             moveq    #0,d0
  2688.             dc.w     $A82A
  2689.         EndM
  2690.     ELSE
  2691.         IMPORT    VDGetKeyColor
  2692.     ENDIF
  2693.  
  2694.     IF GENERATING68K THEN
  2695.         Macro
  2696.         _VDAddKeyColor
  2697.             dc.w     $2F3C
  2698.             dc.w     $0004
  2699.             dc.w     $001D
  2700.             moveq    #0,d0
  2701.             dc.w     $A82A
  2702.         EndM
  2703.     ELSE
  2704.         IMPORT    VDAddKeyColor
  2705.     ENDIF
  2706.  
  2707.     IF GENERATING68K THEN
  2708.         Macro
  2709.         _VDGetNextKeyColor
  2710.             dc.w     $2F3C
  2711.             dc.w     $0004
  2712.             dc.w     $001E
  2713.             moveq    #0,d0
  2714.             dc.w     $A82A
  2715.         EndM
  2716.     ELSE
  2717.         IMPORT    VDGetNextKeyColor
  2718.     ENDIF
  2719.  
  2720.     IF GENERATING68K THEN
  2721.         Macro
  2722.         _VDSetKeyColorRange
  2723.             dc.w     $2F3C
  2724.             dc.w     $0008
  2725.             dc.w     $001F
  2726.             moveq    #0,d0
  2727.             dc.w     $A82A
  2728.         EndM
  2729.     ELSE
  2730.         IMPORT    VDSetKeyColorRange
  2731.     ENDIF
  2732.  
  2733.     IF GENERATING68K THEN
  2734.         Macro
  2735.         _VDGetKeyColorRange
  2736.             dc.w     $2F3C
  2737.             dc.w     $0008
  2738.             dc.w     $0020
  2739.             moveq    #0,d0
  2740.             dc.w     $A82A
  2741.         EndM
  2742.     ELSE
  2743.         IMPORT    VDGetKeyColorRange
  2744.     ENDIF
  2745.  
  2746.     IF GENERATING68K THEN
  2747.         Macro
  2748.         _VDSetDigitizerUserInterrupt
  2749.             dc.w     $2F3C
  2750.             dc.w     $000C
  2751.             dc.w     $0021
  2752.             moveq    #0,d0
  2753.             dc.w     $A82A
  2754.         EndM
  2755.     ELSE
  2756.         IMPORT    VDSetDigitizerUserInterrupt
  2757.     ENDIF
  2758.  
  2759.     IF GENERATING68K THEN
  2760.         Macro
  2761.         _VDSetInputColorSpaceMode
  2762.             dc.w     $2F3C
  2763.             dc.w     $0002
  2764.             dc.w     $0022
  2765.             moveq    #0,d0
  2766.             dc.w     $A82A
  2767.         EndM
  2768.     ELSE
  2769.         IMPORT    VDSetInputColorSpaceMode
  2770.     ENDIF
  2771.  
  2772.     IF GENERATING68K THEN
  2773.         Macro
  2774.         _VDGetInputColorSpaceMode
  2775.             dc.w     $2F3C
  2776.             dc.w     $0004
  2777.             dc.w     $0023
  2778.             moveq    #0,d0
  2779.             dc.w     $A82A
  2780.         EndM
  2781.     ELSE
  2782.         IMPORT    VDGetInputColorSpaceMode
  2783.     ENDIF
  2784.  
  2785.     IF GENERATING68K THEN
  2786.         Macro
  2787.         _VDSetClipState
  2788.             dc.w     $2F3C
  2789.             dc.w     $0002
  2790.             dc.w     $0024
  2791.             moveq    #0,d0
  2792.             dc.w     $A82A
  2793.         EndM
  2794.     ELSE
  2795.         IMPORT    VDSetClipState
  2796.     ENDIF
  2797.  
  2798.     IF GENERATING68K THEN
  2799.         Macro
  2800.         _VDGetClipState
  2801.             dc.w     $2F3C
  2802.             dc.w     $0004
  2803.             dc.w     $0025
  2804.             moveq    #0,d0
  2805.             dc.w     $A82A
  2806.         EndM
  2807.     ELSE
  2808.         IMPORT    VDGetClipState
  2809.     ENDIF
  2810.  
  2811.     IF GENERATING68K THEN
  2812.         Macro
  2813.         _VDSetClipRgn
  2814.             dc.w     $2F3C
  2815.             dc.w     $0004
  2816.             dc.w     $0026
  2817.             moveq    #0,d0
  2818.             dc.w     $A82A
  2819.         EndM
  2820.     ELSE
  2821.         IMPORT    VDSetClipRgn
  2822.     ENDIF
  2823.  
  2824.     IF GENERATING68K THEN
  2825.         Macro
  2826.         _VDClearClipRgn
  2827.             dc.w     $2F3C
  2828.             dc.w     $0004
  2829.             dc.w     $0027
  2830.             moveq    #0,d0
  2831.             dc.w     $A82A
  2832.         EndM
  2833.     ELSE
  2834.         IMPORT    VDClearClipRgn
  2835.     ENDIF
  2836.  
  2837.     IF GENERATING68K THEN
  2838.         Macro
  2839.         _VDGetCLUTInUse
  2840.             dc.w     $2F3C
  2841.             dc.w     $0004
  2842.             dc.w     $0028
  2843.             moveq    #0,d0
  2844.             dc.w     $A82A
  2845.         EndM
  2846.     ELSE
  2847.         IMPORT    VDGetCLUTInUse
  2848.     ENDIF
  2849.  
  2850.     IF GENERATING68K THEN
  2851.         Macro
  2852.         _VDSetPLLFilterType
  2853.             dc.w     $2F3C
  2854.             dc.w     $0002
  2855.             dc.w     $0029
  2856.             moveq    #0,d0
  2857.             dc.w     $A82A
  2858.         EndM
  2859.     ELSE
  2860.         IMPORT    VDSetPLLFilterType
  2861.     ENDIF
  2862.  
  2863.     IF GENERATING68K THEN
  2864.         Macro
  2865.         _VDGetPLLFilterType
  2866.             dc.w     $2F3C
  2867.             dc.w     $0004
  2868.             dc.w     $002A
  2869.             moveq    #0,d0
  2870.             dc.w     $A82A
  2871.         EndM
  2872.     ELSE
  2873.         IMPORT    VDGetPLLFilterType
  2874.     ENDIF
  2875.  
  2876.     IF GENERATING68K THEN
  2877.         Macro
  2878.         _VDGetMaskandValue
  2879.             dc.w     $2F3C
  2880.             dc.w     $000A
  2881.             dc.w     $002B
  2882.             moveq    #0,d0
  2883.             dc.w     $A82A
  2884.         EndM
  2885.     ELSE
  2886.         IMPORT    VDGetMaskandValue
  2887.     ENDIF
  2888.  
  2889.     IF GENERATING68K THEN
  2890.         Macro
  2891.         _VDSetMasterBlendLevel
  2892.             dc.w     $2F3C
  2893.             dc.w     $0004
  2894.             dc.w     $002C
  2895.             moveq    #0,d0
  2896.             dc.w     $A82A
  2897.         EndM
  2898.     ELSE
  2899.         IMPORT    VDSetMasterBlendLevel
  2900.     ENDIF
  2901.  
  2902.     IF GENERATING68K THEN
  2903.         Macro
  2904.         _VDSetPlayThruDestination
  2905.             dc.w     $2F3C
  2906.             dc.w     $0010
  2907.             dc.w     $002D
  2908.             moveq    #0,d0
  2909.             dc.w     $A82A
  2910.         EndM
  2911.     ELSE
  2912.         IMPORT    VDSetPlayThruDestination
  2913.     ENDIF
  2914.  
  2915.     IF GENERATING68K THEN
  2916.         Macro
  2917.         _VDSetPlayThruOnOff
  2918.             dc.w     $2F3C
  2919.             dc.w     $0002
  2920.             dc.w     $002E
  2921.             moveq    #0,d0
  2922.             dc.w     $A82A
  2923.         EndM
  2924.     ELSE
  2925.         IMPORT    VDSetPlayThruOnOff
  2926.     ENDIF
  2927.  
  2928.     IF GENERATING68K THEN
  2929.         Macro
  2930.         _VDSetFieldPreference
  2931.             dc.w     $2F3C
  2932.             dc.w     $0002
  2933.             dc.w     $002F
  2934.             moveq    #0,d0
  2935.             dc.w     $A82A
  2936.         EndM
  2937.     ELSE
  2938.         IMPORT    VDSetFieldPreference
  2939.     ENDIF
  2940.  
  2941.     IF GENERATING68K THEN
  2942.         Macro
  2943.         _VDGetFieldPreference
  2944.             dc.w     $2F3C
  2945.             dc.w     $0004
  2946.             dc.w     $0030
  2947.             moveq    #0,d0
  2948.             dc.w     $A82A
  2949.         EndM
  2950.     ELSE
  2951.         IMPORT    VDGetFieldPreference
  2952.     ENDIF
  2953.  
  2954.     IF GENERATING68K THEN
  2955.         Macro
  2956.         _VDPreflightDestination
  2957.             dc.w     $2F3C
  2958.             dc.w     $0010
  2959.             dc.w     $0032
  2960.             moveq    #0,d0
  2961.             dc.w     $A82A
  2962.         EndM
  2963.     ELSE
  2964.         IMPORT    VDPreflightDestination
  2965.     ENDIF
  2966.  
  2967.     IF GENERATING68K THEN
  2968.         Macro
  2969.         _VDPreflightGlobalRect
  2970.             dc.w     $2F3C
  2971.             dc.w     $0008
  2972.             dc.w     $0033
  2973.             moveq    #0,d0
  2974.             dc.w     $A82A
  2975.         EndM
  2976.     ELSE
  2977.         IMPORT    VDPreflightGlobalRect
  2978.     ENDIF
  2979.  
  2980.     IF GENERATING68K THEN
  2981.         Macro
  2982.         _VDSetPlayThruGlobalRect
  2983.             dc.w     $2F3C
  2984.             dc.w     $0008
  2985.             dc.w     $0034
  2986.             moveq    #0,d0
  2987.             dc.w     $A82A
  2988.         EndM
  2989.     ELSE
  2990.         IMPORT    VDSetPlayThruGlobalRect
  2991.     ENDIF
  2992.  
  2993.     IF GENERATING68K THEN
  2994.         Macro
  2995.         _VDSetInputGammaRecord
  2996.             dc.w     $2F3C
  2997.             dc.w     $0004
  2998.             dc.w     $0035
  2999.             moveq    #0,d0
  3000.             dc.w     $A82A
  3001.         EndM
  3002.     ELSE
  3003.         IMPORT    VDSetInputGammaRecord
  3004.     ENDIF
  3005.  
  3006.     IF GENERATING68K THEN
  3007.         Macro
  3008.         _VDGetInputGammaRecord
  3009.             dc.w     $2F3C
  3010.             dc.w     $0004
  3011.             dc.w     $0036
  3012.             moveq    #0,d0
  3013.             dc.w     $A82A
  3014.         EndM
  3015.     ELSE
  3016.         IMPORT    VDGetInputGammaRecord
  3017.     ENDIF
  3018.  
  3019.     IF GENERATING68K THEN
  3020.         Macro
  3021.         _VDSetBlackLevelValue
  3022.             dc.w     $2F3C
  3023.             dc.w     $0004
  3024.             dc.w     $0037
  3025.             moveq    #0,d0
  3026.             dc.w     $A82A
  3027.         EndM
  3028.     ELSE
  3029.         IMPORT    VDSetBlackLevelValue
  3030.     ENDIF
  3031.  
  3032.     IF GENERATING68K THEN
  3033.         Macro
  3034.         _VDGetBlackLevelValue
  3035.             dc.w     $2F3C
  3036.             dc.w     $0004
  3037.             dc.w     $0038
  3038.             moveq    #0,d0
  3039.             dc.w     $A82A
  3040.         EndM
  3041.     ELSE
  3042.         IMPORT    VDGetBlackLevelValue
  3043.     ENDIF
  3044.  
  3045.     IF GENERATING68K THEN
  3046.         Macro
  3047.         _VDSetWhiteLevelValue
  3048.             dc.w     $2F3C
  3049.             dc.w     $0004
  3050.             dc.w     $0039
  3051.             moveq    #0,d0
  3052.             dc.w     $A82A
  3053.         EndM
  3054.     ELSE
  3055.         IMPORT    VDSetWhiteLevelValue
  3056.     ENDIF
  3057.  
  3058.     IF GENERATING68K THEN
  3059.         Macro
  3060.         _VDGetWhiteLevelValue
  3061.             dc.w     $2F3C
  3062.             dc.w     $0004
  3063.             dc.w     $003A
  3064.             moveq    #0,d0
  3065.             dc.w     $A82A
  3066.         EndM
  3067.     ELSE
  3068.         IMPORT    VDGetWhiteLevelValue
  3069.     ENDIF
  3070.  
  3071.     IF GENERATING68K THEN
  3072.         Macro
  3073.         _VDGetVideoDefaults
  3074.             dc.w     $2F3C
  3075.             dc.w     $001C
  3076.             dc.w     $003B
  3077.             moveq    #0,d0
  3078.             dc.w     $A82A
  3079.         EndM
  3080.     ELSE
  3081.         IMPORT    VDGetVideoDefaults
  3082.     ENDIF
  3083.  
  3084.     IF GENERATING68K THEN
  3085.         Macro
  3086.         _VDGetNumberOfInputs
  3087.             dc.w     $2F3C
  3088.             dc.w     $0004
  3089.             dc.w     $003C
  3090.             moveq    #0,d0
  3091.             dc.w     $A82A
  3092.         EndM
  3093.     ELSE
  3094.         IMPORT    VDGetNumberOfInputs
  3095.     ENDIF
  3096.  
  3097.     IF GENERATING68K THEN
  3098.         Macro
  3099.         _VDGetInputFormat
  3100.             dc.w     $2F3C
  3101.             dc.w     $0006
  3102.             dc.w     $003D
  3103.             moveq    #0,d0
  3104.             dc.w     $A82A
  3105.         EndM
  3106.     ELSE
  3107.         IMPORT    VDGetInputFormat
  3108.     ENDIF
  3109.  
  3110.     IF GENERATING68K THEN
  3111.         Macro
  3112.         _VDSetInput
  3113.             dc.w     $2F3C
  3114.             dc.w     $0002
  3115.             dc.w     $003E
  3116.             moveq    #0,d0
  3117.             dc.w     $A82A
  3118.         EndM
  3119.     ELSE
  3120.         IMPORT    VDSetInput
  3121.     ENDIF
  3122.  
  3123.     IF GENERATING68K THEN
  3124.         Macro
  3125.         _VDGetInput
  3126.             dc.w     $2F3C
  3127.             dc.w     $0004
  3128.             dc.w     $003F
  3129.             moveq    #0,d0
  3130.             dc.w     $A82A
  3131.         EndM
  3132.     ELSE
  3133.         IMPORT    VDGetInput
  3134.     ENDIF
  3135.  
  3136.     IF GENERATING68K THEN
  3137.         Macro
  3138.         _VDSetInputStandard
  3139.             dc.w     $2F3C
  3140.             dc.w     $0002
  3141.             dc.w     $0040
  3142.             moveq    #0,d0
  3143.             dc.w     $A82A
  3144.         EndM
  3145.     ELSE
  3146.         IMPORT    VDSetInputStandard
  3147.     ENDIF
  3148.  
  3149.     IF GENERATING68K THEN
  3150.         Macro
  3151.         _VDSetupBuffers
  3152.             dc.w     $2F3C
  3153.             dc.w     $0004
  3154.             dc.w     $0041
  3155.             moveq    #0,d0
  3156.             dc.w     $A82A
  3157.         EndM
  3158.     ELSE
  3159.         IMPORT    VDSetupBuffers
  3160.     ENDIF
  3161.  
  3162.     IF GENERATING68K THEN
  3163.         Macro
  3164.         _VDGrabOneFrameAsync
  3165.             dc.w     $2F3C
  3166.             dc.w     $0002
  3167.             dc.w     $0042
  3168.             moveq    #0,d0
  3169.             dc.w     $A82A
  3170.         EndM
  3171.     ELSE
  3172.         IMPORT    VDGrabOneFrameAsync
  3173.     ENDIF
  3174.  
  3175.     IF GENERATING68K THEN
  3176.         Macro
  3177.         _VDDone
  3178.             dc.w     $2F3C
  3179.             dc.w     $0002
  3180.             dc.w     $0043
  3181.             moveq    #0,d0
  3182.             dc.w     $A82A
  3183.         EndM
  3184.     ELSE
  3185.         IMPORT    VDDone
  3186.     ENDIF
  3187.  
  3188.     IF GENERATING68K THEN
  3189.         Macro
  3190.         _VDSetCompression
  3191.             dc.w     $2F3C
  3192.             dc.w     $0016
  3193.             dc.w     $0044
  3194.             moveq    #0,d0
  3195.             dc.w     $A82A
  3196.         EndM
  3197.     ELSE
  3198.         IMPORT    VDSetCompression
  3199.     ENDIF
  3200.  
  3201.     IF GENERATING68K THEN
  3202.         Macro
  3203.         _VDCompressOneFrameAsync
  3204.             dc.w     $2F3C
  3205.             dc.w     $0000
  3206.             dc.w     $0045
  3207.             moveq    #0,d0
  3208.             dc.w     $A82A
  3209.         EndM
  3210.     ELSE
  3211.         IMPORT    VDCompressOneFrameAsync
  3212.     ENDIF
  3213.  
  3214.     IF GENERATING68K THEN
  3215.         Macro
  3216.         _VDCompressDone
  3217.             dc.w     $2F3C
  3218.             dc.w     $0014
  3219.             dc.w     $0046
  3220.             moveq    #0,d0
  3221.             dc.w     $A82A
  3222.         EndM
  3223.     ELSE
  3224.         IMPORT    VDCompressDone
  3225.     ENDIF
  3226.  
  3227.     IF GENERATING68K THEN
  3228.         Macro
  3229.         _VDReleaseCompressBuffer
  3230.             dc.w     $2F3C
  3231.             dc.w     $0004
  3232.             dc.w     $0047
  3233.             moveq    #0,d0
  3234.             dc.w     $A82A
  3235.         EndM
  3236.     ELSE
  3237.         IMPORT    VDReleaseCompressBuffer
  3238.     ENDIF
  3239.  
  3240.     IF GENERATING68K THEN
  3241.         Macro
  3242.         _VDGetImageDescription
  3243.             dc.w     $2F3C
  3244.             dc.w     $0004
  3245.             dc.w     $0048
  3246.             moveq    #0,d0
  3247.             dc.w     $A82A
  3248.         EndM
  3249.     ELSE
  3250.         IMPORT    VDGetImageDescription
  3251.     ENDIF
  3252.  
  3253.     IF GENERATING68K THEN
  3254.         Macro
  3255.         _VDResetCompressSequence
  3256.             dc.w     $2F3C
  3257.             dc.w     $0000
  3258.             dc.w     $0049
  3259.             moveq    #0,d0
  3260.             dc.w     $A82A
  3261.         EndM
  3262.     ELSE
  3263.         IMPORT    VDResetCompressSequence
  3264.     ENDIF
  3265.  
  3266.     IF GENERATING68K THEN
  3267.         Macro
  3268.         _VDSetCompressionOnOff
  3269.             dc.w     $2F3C
  3270.             dc.w     $0002
  3271.             dc.w     $004A
  3272.             moveq    #0,d0
  3273.             dc.w     $A82A
  3274.         EndM
  3275.     ELSE
  3276.         IMPORT    VDSetCompressionOnOff
  3277.     ENDIF
  3278.  
  3279.     IF GENERATING68K THEN
  3280.         Macro
  3281.         _VDGetCompressionTypes
  3282.             dc.w     $2F3C
  3283.             dc.w     $0004
  3284.             dc.w     $004B
  3285.             moveq    #0,d0
  3286.             dc.w     $A82A
  3287.         EndM
  3288.     ELSE
  3289.         IMPORT    VDGetCompressionTypes
  3290.     ENDIF
  3291.  
  3292.     IF GENERATING68K THEN
  3293.         Macro
  3294.         _VDSetTimeBase
  3295.             dc.w     $2F3C
  3296.             dc.w     $0004
  3297.             dc.w     $004C
  3298.             moveq    #0,d0
  3299.             dc.w     $A82A
  3300.         EndM
  3301.     ELSE
  3302.         IMPORT    VDSetTimeBase
  3303.     ENDIF
  3304.  
  3305.     IF GENERATING68K THEN
  3306.         Macro
  3307.         _VDSetFrameRate
  3308.             dc.w     $2F3C
  3309.             dc.w     $0004
  3310.             dc.w     $004D
  3311.             moveq    #0,d0
  3312.             dc.w     $A82A
  3313.         EndM
  3314.     ELSE
  3315.         IMPORT    VDSetFrameRate
  3316.     ENDIF
  3317.  
  3318.     IF GENERATING68K THEN
  3319.         Macro
  3320.         _VDGetDataRate
  3321.             dc.w     $2F3C
  3322.             dc.w     $000C
  3323.             dc.w     $004E
  3324.             moveq    #0,d0
  3325.             dc.w     $A82A
  3326.         EndM
  3327.     ELSE
  3328.         IMPORT    VDGetDataRate
  3329.     ENDIF
  3330.  
  3331.     IF GENERATING68K THEN
  3332.         Macro
  3333.         _VDGetSoundInputDriver
  3334.             dc.w     $2F3C
  3335.             dc.w     $0004
  3336.             dc.w     $004F
  3337.             moveq    #0,d0
  3338.             dc.w     $A82A
  3339.         EndM
  3340.     ELSE
  3341.         IMPORT    VDGetSoundInputDriver
  3342.     ENDIF
  3343.  
  3344.     IF GENERATING68K THEN
  3345.         Macro
  3346.         _VDGetDMADepths
  3347.             dc.w     $2F3C
  3348.             dc.w     $0008
  3349.             dc.w     $0050
  3350.             moveq    #0,d0
  3351.             dc.w     $A82A
  3352.         EndM
  3353.     ELSE
  3354.         IMPORT    VDGetDMADepths
  3355.     ENDIF
  3356.  
  3357.     IF GENERATING68K THEN
  3358.         Macro
  3359.         _VDGetPreferredTimeScale
  3360.             dc.w     $2F3C
  3361.             dc.w     $0004
  3362.             dc.w     $0051
  3363.             moveq    #0,d0
  3364.             dc.w     $A82A
  3365.         EndM
  3366.     ELSE
  3367.         IMPORT    VDGetPreferredTimeScale
  3368.     ENDIF
  3369.  
  3370.     IF GENERATING68K THEN
  3371.         Macro
  3372.         _VDReleaseAsyncBuffers
  3373.             dc.w     $2F3C
  3374.             dc.w     $0000
  3375.             dc.w     $0052
  3376.             moveq    #0,d0
  3377.             dc.w     $A82A
  3378.         EndM
  3379.     ELSE
  3380.         IMPORT    VDReleaseAsyncBuffers
  3381.     ENDIF
  3382.  
  3383. ; 83 is reserved for compatibility reasons 
  3384.     IF GENERATING68K THEN
  3385.         Macro
  3386.         _VDSetDataRate
  3387.             dc.w     $2F3C
  3388.             dc.w     $0004
  3389.             dc.w     $0054
  3390.             moveq    #0,d0
  3391.             dc.w     $A82A
  3392.         EndM
  3393.     ELSE
  3394.         IMPORT    VDSetDataRate
  3395.     ENDIF
  3396.  
  3397.     IF GENERATING68K THEN
  3398.         Macro
  3399.         _VDGetTimeCode
  3400.             dc.w     $2F3C
  3401.             dc.w     $000C
  3402.             dc.w     $0055
  3403.             moveq    #0,d0
  3404.             dc.w     $A82A
  3405.         EndM
  3406.     ELSE
  3407.         IMPORT    VDGetTimeCode
  3408.     ENDIF
  3409.  
  3410.     IF GENERATING68K THEN
  3411.         Macro
  3412.         _VDUseSafeBuffers
  3413.             dc.w     $2F3C
  3414.             dc.w     $0002
  3415.             dc.w     $0056
  3416.             moveq    #0,d0
  3417.             dc.w     $A82A
  3418.         EndM
  3419.     ELSE
  3420.         IMPORT    VDUseSafeBuffers
  3421.     ENDIF
  3422.  
  3423. kSelectVDGetMaxSrcRect            EQU        $1
  3424. kSelectVDGetActiveSrcRect        EQU        $2
  3425. kSelectVDSetDigitizerRect        EQU        $3
  3426. kSelectVDGetDigitizerRect        EQU        $4
  3427. kSelectVDGetVBlankRect            EQU        $5
  3428. kSelectVDGetMaskPixMap            EQU        $6
  3429. kSelectVDGetPlayThruDestination    EQU        $8
  3430. kSelectVDUseThisCLUT            EQU        $9
  3431. kSelectVDSetInputGammaValue        EQU        $A
  3432. kSelectVDGetInputGammaValue        EQU        $B
  3433. kSelectVDSetBrightness            EQU        $C
  3434. kSelectVDGetBrightness            EQU        $D
  3435. kSelectVDSetContrast            EQU        $E
  3436. kSelectVDSetHue                    EQU        $F
  3437. kSelectVDSetSharpness            EQU        $10
  3438. kSelectVDSetSaturation            EQU        $11
  3439. kSelectVDGetContrast            EQU        $12
  3440. kSelectVDGetHue                    EQU        $13
  3441. kSelectVDGetSharpness            EQU        $14
  3442. kSelectVDGetSaturation            EQU        $15
  3443. kSelectVDGrabOneFrame            EQU        $16
  3444. kSelectVDGetMaxAuxBuffer        EQU        $17
  3445. kSelectVDGetDigitizerInfo        EQU        $19
  3446. kSelectVDGetCurrentFlags        EQU        $1A
  3447. kSelectVDSetKeyColor            EQU        $1B
  3448. kSelectVDGetKeyColor            EQU        $1C
  3449. kSelectVDAddKeyColor            EQU        $1D
  3450. kSelectVDGetNextKeyColor        EQU        $1E
  3451. kSelectVDSetKeyColorRange        EQU        $1F
  3452. kSelectVDGetKeyColorRange        EQU        $20
  3453. kSelectVDSetDigitizerUserInterrupt EQU        $21
  3454. kSelectVDSetInputColorSpaceMode    EQU        $22
  3455. kSelectVDGetInputColorSpaceMode    EQU        $23
  3456. kSelectVDSetClipState            EQU        $24
  3457. kSelectVDGetClipState            EQU        $25
  3458. kSelectVDSetClipRgn                EQU        $26
  3459. kSelectVDClearClipRgn            EQU        $27
  3460. kSelectVDGetCLUTInUse            EQU        $28
  3461. kSelectVDSetPLLFilterType        EQU        $29
  3462. kSelectVDGetPLLFilterType        EQU        $2A
  3463. kSelectVDGetMaskandValue        EQU        $2B
  3464. kSelectVDSetMasterBlendLevel    EQU        $2C
  3465. kSelectVDSetPlayThruDestination    EQU        $2D
  3466. kSelectVDSetPlayThruOnOff        EQU        $2E
  3467. kSelectVDSetFieldPreference        EQU        $2F
  3468. kSelectVDGetFieldPreference        EQU        $30
  3469. kSelectVDPreflightDestination    EQU        $32
  3470. kSelectVDPreflightGlobalRect    EQU        $33
  3471. kSelectVDSetPlayThruGlobalRect    EQU        $34
  3472. kSelectVDSetInputGammaRecord    EQU        $35
  3473. kSelectVDGetInputGammaRecord    EQU        $36
  3474. kSelectVDSetBlackLevelValue        EQU        $37
  3475. kSelectVDGetBlackLevelValue        EQU        $38
  3476. kSelectVDSetWhiteLevelValue        EQU        $39
  3477. kSelectVDGetWhiteLevelValue        EQU        $3A
  3478. kSelectVDGetVideoDefaults        EQU        $3B
  3479. kSelectVDGetNumberOfInputs        EQU        $3C
  3480. kSelectVDGetInputFormat            EQU        $3D
  3481. kSelectVDSetInput                EQU        $3E
  3482. kSelectVDGetInput                EQU        $3F
  3483. kSelectVDSetInputStandard        EQU        $40
  3484. kSelectVDSetupBuffers            EQU        $41
  3485. kSelectVDGrabOneFrameAsync        EQU        $42
  3486. kSelectVDDone                    EQU        $43
  3487. kSelectVDSetCompression            EQU        $44
  3488. kSelectVDCompressOneFrameAsync    EQU        $45
  3489. kSelectVDCompressDone            EQU        $46
  3490. kSelectVDReleaseCompressBuffer    EQU        $47
  3491. kSelectVDGetImageDescription    EQU        $48
  3492. kSelectVDResetCompressSequence    EQU        $49
  3493. kSelectVDSetCompressionOnOff    EQU        $4A
  3494. kSelectVDGetCompressionTypes    EQU        $4B
  3495. kSelectVDSetTimeBase            EQU        $4C
  3496. kSelectVDSetFrameRate            EQU        $4D
  3497. kSelectVDGetDataRate            EQU        $4E
  3498. kSelectVDGetSoundInputDriver    EQU        $4F
  3499. kSelectVDGetDMADepths            EQU        $50
  3500. kSelectVDGetPreferredTimeScale    EQU        $51
  3501. kSelectVDReleaseAsyncBuffers    EQU        $52
  3502. kSelectVDSetDataRate            EQU        $54
  3503. kSelectVDGetTimeCode            EQU        $55
  3504. kSelectVDUseSafeBuffers            EQU        $56
  3505.  
  3506. StandardCompressionType            EQU        'scdi'
  3507. StandardCompressionSubType        EQU        'imag'
  3508.  
  3509. scListEveryCodec                EQU        1 << 1
  3510. scAllowZeroFrameRate            EQU        1 << 2
  3511. scAllowZeroKeyFrameRate            EQU        1 << 3
  3512. scShowBestDepth                    EQU        1 << 4
  3513. scUseMovableModal                EQU        1 << 5
  3514.  
  3515. ;    Possible test flags for setting test image.
  3516. scPreferCropping                EQU        1 << 0
  3517. scPreferScaling                    EQU        1 << 1
  3518. scPreferScalingAndCropping        EQU        scPreferScaling | scPreferCropping
  3519.  
  3520. ;    Dimensions of the image preview box.
  3521. scTestImageWidth                EQU        80
  3522. scTestImageHeight                EQU        80
  3523.  
  3524. ;    Possible items returned by hookProc.
  3525. scOKItem                        EQU        1
  3526. scCancelItem                    EQU        2
  3527. scCustomItem                    EQU        3
  3528.  
  3529. ;    Result returned when user cancelled.
  3530. scUserCancelled                    EQU        1
  3531.  
  3532. SCSpatialSettings         RECORD    0
  3533. codecType                 ds.l    1
  3534. codec                     ds.l    1
  3535. depth                     ds.w    1
  3536. spatialQuality             ds.l    1
  3537. sizeof                     EQU    14
  3538.                         ENDR
  3539.  
  3540. SCTemporalSettings         RECORD    0
  3541. temporalQuality             ds.l    1
  3542. frameRate                 ds.l    1
  3543. keyFrameRate             ds.l    1
  3544. sizeof                     EQU    12
  3545.                         ENDR
  3546.  
  3547. SCDataRateSettings         RECORD    0
  3548. dataRate                 ds.l    1
  3549. frameDuration             ds.l    1
  3550. minSpatialQuality         ds.l    1
  3551. minTemporalQuality         ds.l    1
  3552. sizeof                     EQU    16
  3553.                         ENDR
  3554.  
  3555. SCExtendedProcs         RECORD    0
  3556. filterProc                 ds.l    1
  3557. hookProc                 ds.l    1
  3558. refcon                     ds.l    1
  3559. customName                 ds.l    8
  3560. sizeof                     EQU    44
  3561.                         ENDR
  3562.  
  3563. ;    Get/SetInfo selectors
  3564.  
  3565. scSpatialSettingsType            EQU        'sptl'                ; pointer to SCSpatialSettings struct
  3566. scTemporalSettingsType            EQU        'tprl'                ; pointer to SCTemporalSettings struct
  3567. scDataRateSettingsType            EQU        'drat'                ; pointer to SCDataRateSettings struct
  3568. scColorTableType                EQU        'clut'                ; pointer to CTabHandle
  3569. scProgressProcType                EQU        'prog'                ; pointer to ProgressRecord struct
  3570. scExtendedProcsType                EQU        'xprc'                ; pointer to SCExtendedProcs struct
  3571. scPreferenceFlagsType            EQU        'pref'                ; pointer to long
  3572. scSettingsStateType                EQU        'ssta'                ; pointer to Handle
  3573. scSequenceIDType                EQU        'sequ'                ; pointer to ImageSequence
  3574. scWindowPositionType            EQU        'wndw'                ; pointer to Point
  3575. scCodecFlagsType                EQU        'cflg'                ; pointer to CodecFlags
  3576. scCodecSettingsType                EQU        'cdec'                ; pointer to Handle
  3577. scForceKeyValueType                EQU        'ksim'
  3578.  
  3579. ;    scTypeNotFoundErr returned by Get/SetInfo when type cannot be found.
  3580. ;* These are Progress procedures *
  3581.     IF GENERATING68K THEN
  3582.         Macro
  3583.         _SCPositionRect
  3584.             dc.w     $2F3C
  3585.             dc.w     $0008
  3586.             dc.w     $0002
  3587.             moveq    #0,d0
  3588.             dc.w     $A82A
  3589.         EndM
  3590.     ELSE
  3591.         IMPORT    SCPositionRect
  3592.     ENDIF
  3593.  
  3594.     IF GENERATING68K THEN
  3595.         Macro
  3596.         _SCPositionDialog
  3597.             dc.w     $2F3C
  3598.             dc.w     $0006
  3599.             dc.w     $0003
  3600.             moveq    #0,d0
  3601.             dc.w     $A82A
  3602.         EndM
  3603.     ELSE
  3604.         IMPORT    SCPositionDialog
  3605.     ENDIF
  3606.  
  3607.     IF GENERATING68K THEN
  3608.         Macro
  3609.         _SCSetTestImagePictHandle
  3610.             dc.w     $2F3C
  3611.             dc.w     $000A
  3612.             dc.w     $0004
  3613.             moveq    #0,d0
  3614.             dc.w     $A82A
  3615.         EndM
  3616.     ELSE
  3617.         IMPORT    SCSetTestImagePictHandle
  3618.     ENDIF
  3619.  
  3620.     IF GENERATING68K THEN
  3621.         Macro
  3622.         _SCSetTestImagePictFile
  3623.             dc.w     $2F3C
  3624.             dc.w     $0008
  3625.             dc.w     $0005
  3626.             moveq    #0,d0
  3627.             dc.w     $A82A
  3628.         EndM
  3629.     ELSE
  3630.         IMPORT    SCSetTestImagePictFile
  3631.     ENDIF
  3632.  
  3633.     IF GENERATING68K THEN
  3634.         Macro
  3635.         _SCSetTestImagePixMap
  3636.             dc.w     $2F3C
  3637.             dc.w     $000A
  3638.             dc.w     $0006
  3639.             moveq    #0,d0
  3640.             dc.w     $A82A
  3641.         EndM
  3642.     ELSE
  3643.         IMPORT    SCSetTestImagePixMap
  3644.     ENDIF
  3645.  
  3646.     IF GENERATING68K THEN
  3647.         Macro
  3648.         _SCGetBestDeviceRect
  3649.             dc.w     $2F3C
  3650.             dc.w     $0004
  3651.             dc.w     $0007
  3652.             moveq    #0,d0
  3653.             dc.w     $A82A
  3654.         EndM
  3655.     ELSE
  3656.         IMPORT    SCGetBestDeviceRect
  3657.     ENDIF
  3658.  
  3659.     IF GENERATING68K THEN
  3660.         Macro
  3661.         _SCRequestImageSettings
  3662.             dc.w     $2F3C
  3663.             dc.w     $0000
  3664.             dc.w     $000A
  3665.             moveq    #0,d0
  3666.             dc.w     $A82A
  3667.         EndM
  3668.     ELSE
  3669.         IMPORT    SCRequestImageSettings
  3670.     ENDIF
  3671.  
  3672.     IF GENERATING68K THEN
  3673.         Macro
  3674.         _SCCompressImage
  3675.             dc.w     $2F3C
  3676.             dc.w     $0010
  3677.             dc.w     $000B
  3678.             moveq    #0,d0
  3679.             dc.w     $A82A
  3680.         EndM
  3681.     ELSE
  3682.         IMPORT    SCCompressImage
  3683.     ENDIF
  3684.  
  3685.     IF GENERATING68K THEN
  3686.         Macro
  3687.         _SCCompressPicture
  3688.             dc.w     $2F3C
  3689.             dc.w     $0008
  3690.             dc.w     $000C
  3691.             moveq    #0,d0
  3692.             dc.w     $A82A
  3693.         EndM
  3694.     ELSE
  3695.         IMPORT    SCCompressPicture
  3696.     ENDIF
  3697.  
  3698.     IF GENERATING68K THEN
  3699.         Macro
  3700.         _SCCompressPictureFile
  3701.             dc.w     $2F3C
  3702.             dc.w     $0004
  3703.             dc.w     $000D
  3704.             moveq    #0,d0
  3705.             dc.w     $A82A
  3706.         EndM
  3707.     ELSE
  3708.         IMPORT    SCCompressPictureFile
  3709.     ENDIF
  3710.  
  3711.     IF GENERATING68K THEN
  3712.         Macro
  3713.         _SCRequestSequenceSettings
  3714.             dc.w     $2F3C
  3715.             dc.w     $0000
  3716.             dc.w     $000E
  3717.             moveq    #0,d0
  3718.             dc.w     $A82A
  3719.         EndM
  3720.     ELSE
  3721.         IMPORT    SCRequestSequenceSettings
  3722.     ENDIF
  3723.  
  3724.     IF GENERATING68K THEN
  3725.         Macro
  3726.         _SCCompressSequenceBegin
  3727.             dc.w     $2F3C
  3728.             dc.w     $000C
  3729.             dc.w     $000F
  3730.             moveq    #0,d0
  3731.             dc.w     $A82A
  3732.         EndM
  3733.     ELSE
  3734.         IMPORT    SCCompressSequenceBegin
  3735.     ENDIF
  3736.  
  3737.     IF GENERATING68K THEN
  3738.         Macro
  3739.         _SCCompressSequenceFrame
  3740.             dc.w     $2F3C
  3741.             dc.w     $0014
  3742.             dc.w     $0010
  3743.             moveq    #0,d0
  3744.             dc.w     $A82A
  3745.         EndM
  3746.     ELSE
  3747.         IMPORT    SCCompressSequenceFrame
  3748.     ENDIF
  3749.  
  3750.     IF GENERATING68K THEN
  3751.         Macro
  3752.         _SCCompressSequenceEnd
  3753.             dc.w     $2F3C
  3754.             dc.w     $0000
  3755.             dc.w     $0011
  3756.             moveq    #0,d0
  3757.             dc.w     $A82A
  3758.         EndM
  3759.     ELSE
  3760.         IMPORT    SCCompressSequenceEnd
  3761.     ENDIF
  3762.  
  3763.     IF GENERATING68K THEN
  3764.         Macro
  3765.         _SCDefaultPictHandleSettings
  3766.             dc.w     $2F3C
  3767.             dc.w     $0006
  3768.             dc.w     $0012
  3769.             moveq    #0,d0
  3770.             dc.w     $A82A
  3771.         EndM
  3772.     ELSE
  3773.         IMPORT    SCDefaultPictHandleSettings
  3774.     ENDIF
  3775.  
  3776.     IF GENERATING68K THEN
  3777.         Macro
  3778.         _SCDefaultPictFileSettings
  3779.             dc.w     $2F3C
  3780.             dc.w     $0004
  3781.             dc.w     $0013
  3782.             moveq    #0,d0
  3783.             dc.w     $A82A
  3784.         EndM
  3785.     ELSE
  3786.         IMPORT    SCDefaultPictFileSettings
  3787.     ENDIF
  3788.  
  3789.     IF GENERATING68K THEN
  3790.         Macro
  3791.         _SCDefaultPixMapSettings
  3792.             dc.w     $2F3C
  3793.             dc.w     $0006
  3794.             dc.w     $0014
  3795.             moveq    #0,d0
  3796.             dc.w     $A82A
  3797.         EndM
  3798.     ELSE
  3799.         IMPORT    SCDefaultPixMapSettings
  3800.     ENDIF
  3801.  
  3802.     IF GENERATING68K THEN
  3803.         Macro
  3804.         _SCGetInfo
  3805.             dc.w     $2F3C
  3806.             dc.w     $0008
  3807.             dc.w     $0015
  3808.             moveq    #0,d0
  3809.             dc.w     $A82A
  3810.         EndM
  3811.     ELSE
  3812.         IMPORT    SCGetInfo
  3813.     ENDIF
  3814.  
  3815.     IF GENERATING68K THEN
  3816.         Macro
  3817.         _SCSetInfo
  3818.             dc.w     $2F3C
  3819.             dc.w     $0008
  3820.             dc.w     $0016
  3821.             moveq    #0,d0
  3822.             dc.w     $A82A
  3823.         EndM
  3824.     ELSE
  3825.         IMPORT    SCSetInfo
  3826.     ENDIF
  3827.  
  3828.     IF GENERATING68K THEN
  3829.         Macro
  3830.         _SCNewGWorld
  3831.             dc.w     $2F3C
  3832.             dc.w     $000C
  3833.             dc.w     $0017
  3834.             moveq    #0,d0
  3835.             dc.w     $A82A
  3836.         EndM
  3837.     ELSE
  3838.         IMPORT    SCNewGWorld
  3839.     ENDIF
  3840.  
  3841.     IF GENERATING68K THEN
  3842.         Macro
  3843.         _SCSetCompressFlags
  3844.             dc.w     $2F3C
  3845.             dc.w     $0004
  3846.             dc.w     $0018
  3847.             moveq    #0,d0
  3848.             dc.w     $A82A
  3849.         EndM
  3850.     ELSE
  3851.         IMPORT    SCSetCompressFlags
  3852.     ENDIF
  3853.  
  3854.     IF GENERATING68K THEN
  3855.         Macro
  3856.         _SCGetCompressFlags
  3857.             dc.w     $2F3C
  3858.             dc.w     $0004
  3859.             dc.w     $0019
  3860.             moveq    #0,d0
  3861.             dc.w     $A82A
  3862.         EndM
  3863.     ELSE
  3864.         IMPORT    SCGetCompressFlags
  3865.     ENDIF
  3866.  
  3867. SCParams                 RECORD    0
  3868. flags                     ds.l    1
  3869. theCodecType             ds.l    1
  3870. theCodec                 ds.l    1
  3871. spatialQuality             ds.l    1
  3872. temporalQuality             ds.l    1
  3873. depth                     ds.w    1
  3874. frameRate                 ds.l    1
  3875. keyFrameRate             ds.l    1
  3876. reserved1                 ds.l    1
  3877. reserved2                 ds.l    1
  3878. sizeof                     EQU    38
  3879.                         ENDR
  3880.  
  3881.  
  3882. scGetCompression                EQU        1
  3883. scShowMotionSettings            EQU        1 << 0
  3884. scSettingsChangedItem            EQU        -1
  3885.  
  3886. scCompressFlagIgnoreIdenticalFrames EQU        1
  3887.  
  3888.     IF GENERATING68K THEN
  3889.         Macro
  3890.         _SCGetCompressionExtended
  3891.             dc.w     $2F3C
  3892.             dc.w     $0018
  3893.             dc.w     $0001
  3894.             moveq    #0,d0
  3895.             dc.w     $A82A
  3896.         EndM
  3897.     ELSE
  3898.         IMPORT    SCGetCompressionExtended
  3899.     ENDIF
  3900.  
  3901. kSCPositionRectSelect            EQU        $2
  3902. kSCPositionDialogSelect            EQU        $3
  3903. kSCSetTestImagePictHandleSelect    EQU        $4
  3904. kSCSetTestImagePictFileSelect    EQU        $5
  3905. kSCSetTestImagePixMapSelect        EQU        $6
  3906. kSCGetBestDeviceRectSelect        EQU        $7
  3907. kSCRequestImageSettingsSelect    EQU        $A
  3908. kSCCompressImageSelect            EQU        $B
  3909. kSCCompressPictureSelect        EQU        $C
  3910. kSCCompressPictureFileSelect    EQU        $D
  3911. kSCRequestSequenceSettingsSelect EQU        $E
  3912. kSCCompressSequenceBeginSelect    EQU        $F
  3913. kSCCompressSequenceFrameSelect    EQU        $10
  3914. kSCCompressSequenceEndSelect    EQU        $11
  3915. kSCDefaultPictHandleSettingsSelect EQU        $12
  3916. kSCDefaultPictFileSettingsSelect EQU        $13
  3917. kSCDefaultPixMapSettingsSelect    EQU        $14
  3918. kSCGetInfoSelect                EQU        $15
  3919. kSCSetInfoSelect                EQU        $16
  3920. kSCNewGWorldSelect                EQU        $17
  3921. kSCSetCompressFlagsSelect        EQU        $18
  3922. kSCGetCompressFlagsSelect        EQU        $19
  3923. kSCGetCompressionExtendedSelect    EQU        $1
  3924.  
  3925. MovieImportType                    EQU        'eat '
  3926. MovieExportType                    EQU        'spit'
  3927.  
  3928. canMovieImportHandles            EQU        1 << 0
  3929. canMovieImportFiles                EQU        1 << 1
  3930. hasMovieImportUserInterface        EQU        1 << 2
  3931. canMovieExportHandles            EQU        1 << 3
  3932. canMovieExportFiles                EQU        1 << 4
  3933. hasMovieExportUserInterface        EQU        1 << 5
  3934. dontAutoFileMovieImport            EQU        1 << 6
  3935. canMovieExportAuxDataHandle        EQU        1 << 7
  3936. canMovieImportValidateHandles    EQU        1 << 8
  3937. canMovieImportValidateFile        EQU        1 << 9
  3938. dontRegisterWithEasyOpen        EQU        1 << 10
  3939. canMovieImportInPlace            EQU        1 << 11
  3940. movieImportSubTypeIsFileExtension EQU        1 << 12
  3941.  
  3942. kMovieImportExportOpenSelect    EQU        kComponentOpenSelect
  3943. kMovieImportExportCloseSelect    EQU        kComponentCloseSelect
  3944. kMovieImportExportCanDoSelect    EQU        kComponentCanDoSelect
  3945. kMovieImportExportVersionSelect    EQU        kComponentVersionSelect
  3946. kMovieImportHandleSelect        EQU        1
  3947. kMovieImportFileSelect            EQU        2
  3948. kMovieImportSetSampleDurationSelect EQU        3
  3949. kMovieImportSetSampleDescriptionSelect EQU        4
  3950. kMovieImportSetMediaFileSelect    EQU        5
  3951. kMovieImportSetDimensionsSelect    EQU        6
  3952. kMovieImportSetChunkSizeSelect    EQU        7
  3953. kMovieImportSetProgressProcSelect EQU        8
  3954. kMovieImportSetAuxiliaryDataSelect EQU        9
  3955. kMovieImportSetFromScrapSelect    EQU        10
  3956. kMovieImportDoUserDialogSelect    EQU        11
  3957. kMovieImportSetDurationSelect    EQU        12
  3958. kMovieImportGetAuxiliaryDataTypeSelect EQU        13
  3959. kMovieImportValidateSelect        EQU        14
  3960. kMovieImportGetFileTypeSelect    EQU        15
  3961. kMovieExportToHandleSelect        EQU        128
  3962. kMovieExportToFileSelect        EQU        129
  3963. kMovieExportDoUserDialogSelectOBSOLETE EQU        130
  3964. kMovieExportGetAuxiliaryDataSelect EQU        131
  3965. kMovieExportSetProgressProcSelect EQU        132
  3966. kMovieExportSetSampleDescriptionSelect EQU        133
  3967. kMovieExportDoUserDialogSelect    EQU        134
  3968. kMovieExportGetCreatorTypeSelect EQU        135
  3969.  
  3970. movieImportCreateTrack            EQU        1
  3971. movieImportInParallel            EQU        2
  3972. movieImportMustUseTrack            EQU        4
  3973.  
  3974. movieImportResultUsedMultipleTracks EQU        8
  3975.  
  3976.     IF GENERATING68K THEN
  3977.         Macro
  3978.         _MovieImportHandle
  3979.             dc.w     $2F3C
  3980.             dc.w     $0020
  3981.             dc.w     $0001
  3982.             moveq    #0,d0
  3983.             dc.w     $A82A
  3984.         EndM
  3985.     ELSE
  3986.         IMPORT    MovieImportHandle
  3987.     ENDIF
  3988.  
  3989.     IF GENERATING68K THEN
  3990.         Macro
  3991.         _MovieImportFile
  3992.             dc.w     $2F3C
  3993.             dc.w     $0020
  3994.             dc.w     $0002
  3995.             moveq    #0,d0
  3996.             dc.w     $A82A
  3997.         EndM
  3998.     ELSE
  3999.         IMPORT    MovieImportFile
  4000.     ENDIF
  4001.  
  4002.     IF GENERATING68K THEN
  4003.         Macro
  4004.         _MovieImportSetSampleDuration
  4005.             dc.w     $2F3C
  4006.             dc.w     $0008
  4007.             dc.w     $0003
  4008.             moveq    #0,d0
  4009.             dc.w     $A82A
  4010.         EndM
  4011.     ELSE
  4012.         IMPORT    MovieImportSetSampleDuration
  4013.     ENDIF
  4014.  
  4015.     IF GENERATING68K THEN
  4016.         Macro
  4017.         _MovieImportSetSampleDescription
  4018.             dc.w     $2F3C
  4019.             dc.w     $0008
  4020.             dc.w     $0004
  4021.             moveq    #0,d0
  4022.             dc.w     $A82A
  4023.         EndM
  4024.     ELSE
  4025.         IMPORT    MovieImportSetSampleDescription
  4026.     ENDIF
  4027.  
  4028.     IF GENERATING68K THEN
  4029.         Macro
  4030.         _MovieImportSetMediaFile
  4031.             dc.w     $2F3C
  4032.             dc.w     $0004
  4033.             dc.w     $0005
  4034.             moveq    #0,d0
  4035.             dc.w     $A82A
  4036.         EndM
  4037.     ELSE
  4038.         IMPORT    MovieImportSetMediaFile
  4039.     ENDIF
  4040.  
  4041.     IF GENERATING68K THEN
  4042.         Macro
  4043.         _MovieImportSetDimensions
  4044.             dc.w     $2F3C
  4045.             dc.w     $0008
  4046.             dc.w     $0006
  4047.             moveq    #0,d0
  4048.             dc.w     $A82A
  4049.         EndM
  4050.     ELSE
  4051.         IMPORT    MovieImportSetDimensions
  4052.     ENDIF
  4053.  
  4054.     IF GENERATING68K THEN
  4055.         Macro
  4056.         _MovieImportSetChunkSize
  4057.             dc.w     $2F3C
  4058.             dc.w     $0004
  4059.             dc.w     $0007
  4060.             moveq    #0,d0
  4061.             dc.w     $A82A
  4062.         EndM
  4063.     ELSE
  4064.         IMPORT    MovieImportSetChunkSize
  4065.     ENDIF
  4066.  
  4067.     IF GENERATING68K THEN
  4068.         Macro
  4069.         _MovieImportSetProgressProc
  4070.             dc.w     $2F3C
  4071.             dc.w     $0008
  4072.             dc.w     $0008
  4073.             moveq    #0,d0
  4074.             dc.w     $A82A
  4075.         EndM
  4076.     ELSE
  4077.         IMPORT    MovieImportSetProgressProc
  4078.     ENDIF
  4079.  
  4080.     IF GENERATING68K THEN
  4081.         Macro
  4082.         _MovieImportSetAuxiliaryData
  4083.             dc.w     $2F3C
  4084.             dc.w     $0008
  4085.             dc.w     $0009
  4086.             moveq    #0,d0
  4087.             dc.w     $A82A
  4088.         EndM
  4089.     ELSE
  4090.         IMPORT    MovieImportSetAuxiliaryData
  4091.     ENDIF
  4092.  
  4093.     IF GENERATING68K THEN
  4094.         Macro
  4095.         _MovieImportSetFromScrap
  4096.             dc.w     $2F3C
  4097.             dc.w     $0002
  4098.             dc.w     $000A
  4099.             moveq    #0,d0
  4100.             dc.w     $A82A
  4101.         EndM
  4102.     ELSE
  4103.         IMPORT    MovieImportSetFromScrap
  4104.     ENDIF
  4105.  
  4106.     IF GENERATING68K THEN
  4107.         Macro
  4108.         _MovieImportDoUserDialog
  4109.             dc.w     $2F3C
  4110.             dc.w     $000C
  4111.             dc.w     $000B
  4112.             moveq    #0,d0
  4113.             dc.w     $A82A
  4114.         EndM
  4115.     ELSE
  4116.         IMPORT    MovieImportDoUserDialog
  4117.     ENDIF
  4118.  
  4119.     IF GENERATING68K THEN
  4120.         Macro
  4121.         _MovieImportSetDuration
  4122.             dc.w     $2F3C
  4123.             dc.w     $0004
  4124.             dc.w     $000C
  4125.             moveq    #0,d0
  4126.             dc.w     $A82A
  4127.         EndM
  4128.     ELSE
  4129.         IMPORT    MovieImportSetDuration
  4130.     ENDIF
  4131.  
  4132.     IF GENERATING68K THEN
  4133.         Macro
  4134.         _MovieImportGetAuxiliaryDataType
  4135.             dc.w     $2F3C
  4136.             dc.w     $0004
  4137.             dc.w     $000D
  4138.             moveq    #0,d0
  4139.             dc.w     $A82A
  4140.         EndM
  4141.     ELSE
  4142.         IMPORT    MovieImportGetAuxiliaryDataType
  4143.     ENDIF
  4144.  
  4145.     IF GENERATING68K THEN
  4146.         Macro
  4147.         _MovieImportValidate
  4148.             dc.w     $2F3C
  4149.             dc.w     $000C
  4150.             dc.w     $000E
  4151.             moveq    #0,d0
  4152.             dc.w     $A82A
  4153.         EndM
  4154.     ELSE
  4155.         IMPORT    MovieImportValidate
  4156.     ENDIF
  4157.  
  4158.     IF GENERATING68K THEN
  4159.         Macro
  4160.         _MovieImportGetFileType
  4161.             dc.w     $2F3C
  4162.             dc.w     $0004
  4163.             dc.w     $000F
  4164.             moveq    #0,d0
  4165.             dc.w     $A82A
  4166.         EndM
  4167.     ELSE
  4168.         IMPORT    MovieImportGetFileType
  4169.     ENDIF
  4170.  
  4171.     IF GENERATING68K THEN
  4172.         Macro
  4173.         _MovieExportToHandle
  4174.             dc.w     $2F3C
  4175.             dc.w     $0014
  4176.             dc.w     $0080
  4177.             moveq    #0,d0
  4178.             dc.w     $A82A
  4179.         EndM
  4180.     ELSE
  4181.         IMPORT    MovieExportToHandle
  4182.     ENDIF
  4183.  
  4184.     IF GENERATING68K THEN
  4185.         Macro
  4186.         _MovieExportToFile
  4187.             dc.w     $2F3C
  4188.             dc.w     $0014
  4189.             dc.w     $0081
  4190.             moveq    #0,d0
  4191.             dc.w     $A82A
  4192.         EndM
  4193.     ELSE
  4194.         IMPORT    MovieExportToFile
  4195.     ENDIF
  4196.  
  4197.     IF GENERATING68K THEN
  4198.         Macro
  4199.         _MovieExportGetAuxiliaryData
  4200.             dc.w     $2F3C
  4201.             dc.w     $0008
  4202.             dc.w     $0083
  4203.             moveq    #0,d0
  4204.             dc.w     $A82A
  4205.         EndM
  4206.     ELSE
  4207.         IMPORT    MovieExportGetAuxiliaryData
  4208.     ENDIF
  4209.  
  4210.     IF GENERATING68K THEN
  4211.         Macro
  4212.         _MovieExportSetProgressProc
  4213.             dc.w     $2F3C
  4214.             dc.w     $0008
  4215.             dc.w     $0084
  4216.             moveq    #0,d0
  4217.             dc.w     $A82A
  4218.         EndM
  4219.     ELSE
  4220.         IMPORT    MovieExportSetProgressProc
  4221.     ENDIF
  4222.  
  4223.     IF GENERATING68K THEN
  4224.         Macro
  4225.         _MovieExportSetSampleDescription
  4226.             dc.w     $2F3C
  4227.             dc.w     $0008
  4228.             dc.w     $0085
  4229.             moveq    #0,d0
  4230.             dc.w     $A82A
  4231.         EndM
  4232.     ELSE
  4233.         IMPORT    MovieExportSetSampleDescription
  4234.     ENDIF
  4235.  
  4236.     IF GENERATING68K THEN
  4237.         Macro
  4238.         _MovieExportDoUserDialog
  4239.             dc.w     $2F3C
  4240.             dc.w     $0014
  4241.             dc.w     $0086
  4242.             moveq    #0,d0
  4243.             dc.w     $A82A
  4244.         EndM
  4245.     ELSE
  4246.         IMPORT    MovieExportDoUserDialog
  4247.     ENDIF
  4248.  
  4249.     IF GENERATING68K THEN
  4250.         Macro
  4251.         _MovieExportGetCreatorType
  4252.             dc.w     $2F3C
  4253.             dc.w     $0004
  4254.             dc.w     $0087
  4255.             moveq    #0,d0
  4256.             dc.w     $A82A
  4257.         EndM
  4258.     ELSE
  4259.         IMPORT    MovieExportGetCreatorType
  4260.     ENDIF
  4261.  
  4262.      IF ¬ GENERATINGPOWERPC THEN 
  4263. ; Text Export Display Info data structure
  4264. TextDisplayData         RECORD    0
  4265. displayFlags             ds.l    1
  4266. textJustification         ds.l    1
  4267. bgColor                     ds        RGBColor
  4268. textBox                     ds        Rect
  4269. beginHilite                 ds.w    1
  4270. endHilite                 ds.w    1
  4271. hiliteColor                 ds        RGBColor
  4272. doHiliteColor             ds.b    1
  4273. filler                     ds.b    1
  4274. scrollDelayDur             ds.l    1
  4275. dropShadowOffset         ds        Point
  4276. dropShadowTransparency     ds.w    1
  4277. sizeof                     EQU    44
  4278.                         ENDR
  4279.  
  4280.     ENDIF
  4281.     IF GENERATING68K THEN
  4282.         Macro
  4283.         _TextExportGetDisplayData
  4284.             dc.w     $2F3C
  4285.             dc.w     $0004
  4286.             dc.w     $0100
  4287.             moveq    #0,d0
  4288.             dc.w     $A82A
  4289.         EndM
  4290.     ELSE
  4291.         IMPORT    TextExportGetDisplayData
  4292.     ENDIF
  4293.  
  4294. ;**************
  4295. ;
  4296. ;    File Preview Components
  4297. ;
  4298. ;**************
  4299.  
  4300. pnotComponentWantsEvents        EQU        1
  4301. pnotComponentNeedsNoCache        EQU        2
  4302.  
  4303. kPreviewOpenSelector            EQU        0
  4304. kPreviewCloseSelector            EQU        -1
  4305. kPreviewCanDoSelector            EQU        -2
  4306. kPreviewVersionSelector            EQU        -3
  4307. kPreviewShowDataSelector        EQU        1
  4308. kPreviewMakePreviewSelector        EQU        2
  4309. kPreviewMakePreviewReferenceSelector EQU        3
  4310. kPreviewEventSelector            EQU        4
  4311.  
  4312. ShowFilePreviewComponentType    EQU        'pnot'
  4313. CreateFilePreviewComponentType    EQU        'pmak'
  4314.  
  4315.     IF GENERATING68K THEN
  4316.         Macro
  4317.         _PreviewShowData
  4318.             dc.w     $2F3C
  4319.             dc.w     $000C
  4320.             dc.w     $0001
  4321.             moveq    #0,d0
  4322.             dc.w     $A82A
  4323.         EndM
  4324.     ELSE
  4325.         IMPORT    PreviewShowData
  4326.     ENDIF
  4327.  
  4328.     IF GENERATING68K THEN
  4329.         Macro
  4330.         _PreviewMakePreview
  4331.             dc.w     $2F3C
  4332.             dc.w     $0010
  4333.             dc.w     $0002
  4334.             moveq    #0,d0
  4335.             dc.w     $A82A
  4336.         EndM
  4337.     ELSE
  4338.         IMPORT    PreviewMakePreview
  4339.     ENDIF
  4340.  
  4341.     IF GENERATING68K THEN
  4342.         Macro
  4343.         _PreviewMakePreviewReference
  4344.             dc.w     $2F3C
  4345.             dc.w     $000C
  4346.             dc.w     $0003
  4347.             moveq    #0,d0
  4348.             dc.w     $A82A
  4349.         EndM
  4350.     ELSE
  4351.         IMPORT    PreviewMakePreviewReference
  4352.     ENDIF
  4353.  
  4354.     IF GENERATING68K THEN
  4355.         Macro
  4356.         _PreviewEvent
  4357.             dc.w     $2F3C
  4358.             dc.w     $0008
  4359.             dc.w     $0004
  4360.             moveq    #0,d0
  4361.             dc.w     $A82A
  4362.         EndM
  4363.     ELSE
  4364.         IMPORT    PreviewEvent
  4365.     ENDIF
  4366.  
  4367. kDataHCanRead                    EQU        1 << 0
  4368. kDataHSpecialRead                EQU        1 << 1
  4369. kDataHSpecialReadFile            EQU        1 << 2
  4370. kDataHCanWrite                    EQU        1 << 3
  4371. kDataHSpecialWrite                EQU        1 << 4
  4372. kDataHSpecialWriteFile            EQU        1 << 5
  4373. kDataHCanStreamingWrite            EQU        1 << 6
  4374. kDataHMustCheckDataRef            EQU        1 << 7
  4375.  
  4376. DataHVolumeListRecord     RECORD    0
  4377. vRefNum                     ds.w    1
  4378. flags                     ds.l    1
  4379. sizeof                     EQU    6
  4380.                         ENDR
  4381.  
  4382.  
  4383. kDataHExtendedSchedule            EQU        'xtnd'
  4384.  
  4385. DataHScheduleRecord     RECORD    0
  4386. timeNeededBy             ds        TimeRecord
  4387. extendedID                 ds.l    1                                    ; always is kDataHExtendedSchedule
  4388. extendedVers             ds.l    1                                    ; always set to 0
  4389. priority                 ds.l    1                                    ; 100.0 or more means must have. lower numbers…
  4390. sizeof                     EQU    28
  4391.                         ENDR
  4392.  
  4393.     IF GENERATING68K THEN
  4394.         Macro
  4395.         _DataHGetData
  4396.             dc.w     $2F3C
  4397.             dc.w     $0010
  4398.             dc.w     $0002
  4399.             moveq    #0,d0
  4400.             dc.w     $A82A
  4401.         EndM
  4402.     ELSE
  4403.         IMPORT    DataHGetData
  4404.     ENDIF
  4405.  
  4406.     IF GENERATING68K THEN
  4407.         Macro
  4408.         _DataHPutData
  4409.             dc.w     $2F3C
  4410.             dc.w     $0010
  4411.             dc.w     $0003
  4412.             moveq    #0,d0
  4413.             dc.w     $A82A
  4414.         EndM
  4415.     ELSE
  4416.         IMPORT    DataHPutData
  4417.     ENDIF
  4418.  
  4419.     IF GENERATING68K THEN
  4420.         Macro
  4421.         _DataHFlushData
  4422.             dc.w     $2F3C
  4423.             dc.w     $0000
  4424.             dc.w     $0004
  4425.             moveq    #0,d0
  4426.             dc.w     $A82A
  4427.         EndM
  4428.     ELSE
  4429.         IMPORT    DataHFlushData
  4430.     ENDIF
  4431.  
  4432.     IF GENERATING68K THEN
  4433.         Macro
  4434.         _DataHOpenForWrite
  4435.             dc.w     $2F3C
  4436.             dc.w     $0000
  4437.             dc.w     $0005
  4438.             moveq    #0,d0
  4439.             dc.w     $A82A
  4440.         EndM
  4441.     ELSE
  4442.         IMPORT    DataHOpenForWrite
  4443.     ENDIF
  4444.  
  4445.     IF GENERATING68K THEN
  4446.         Macro
  4447.         _DataHCloseForWrite
  4448.             dc.w     $2F3C
  4449.             dc.w     $0000
  4450.             dc.w     $0006
  4451.             moveq    #0,d0
  4452.             dc.w     $A82A
  4453.         EndM
  4454.     ELSE
  4455.         IMPORT    DataHCloseForWrite
  4456.     ENDIF
  4457.  
  4458.     IF GENERATING68K THEN
  4459.         Macro
  4460.         _DataHOpenForRead
  4461.             dc.w     $2F3C
  4462.             dc.w     $0000
  4463.             dc.w     $0008
  4464.             moveq    #0,d0
  4465.             dc.w     $A82A
  4466.         EndM
  4467.     ELSE
  4468.         IMPORT    DataHOpenForRead
  4469.     ENDIF
  4470.  
  4471.     IF GENERATING68K THEN
  4472.         Macro
  4473.         _DataHCloseForRead
  4474.             dc.w     $2F3C
  4475.             dc.w     $0000
  4476.             dc.w     $0009
  4477.             moveq    #0,d0
  4478.             dc.w     $A82A
  4479.         EndM
  4480.     ELSE
  4481.         IMPORT    DataHCloseForRead
  4482.     ENDIF
  4483.  
  4484.     IF GENERATING68K THEN
  4485.         Macro
  4486.         _DataHSetDataRef
  4487.             dc.w     $2F3C
  4488.             dc.w     $0004
  4489.             dc.w     $000A
  4490.             moveq    #0,d0
  4491.             dc.w     $A82A
  4492.         EndM
  4493.     ELSE
  4494.         IMPORT    DataHSetDataRef
  4495.     ENDIF
  4496.  
  4497.     IF GENERATING68K THEN
  4498.         Macro
  4499.         _DataHGetDataRef
  4500.             dc.w     $2F3C
  4501.             dc.w     $0004
  4502.             dc.w     $000B
  4503.             moveq    #0,d0
  4504.             dc.w     $A82A
  4505.         EndM
  4506.     ELSE
  4507.         IMPORT    DataHGetDataRef
  4508.     ENDIF
  4509.  
  4510.     IF GENERATING68K THEN
  4511.         Macro
  4512.         _DataHCompareDataRef
  4513.             dc.w     $2F3C
  4514.             dc.w     $0008
  4515.             dc.w     $000C
  4516.             moveq    #0,d0
  4517.             dc.w     $A82A
  4518.         EndM
  4519.     ELSE
  4520.         IMPORT    DataHCompareDataRef
  4521.     ENDIF
  4522.  
  4523.     IF GENERATING68K THEN
  4524.         Macro
  4525.         _DataHTask
  4526.             dc.w     $2F3C
  4527.             dc.w     $0000
  4528.             dc.w     $000D
  4529.             moveq    #0,d0
  4530.             dc.w     $A82A
  4531.         EndM
  4532.     ELSE
  4533.         IMPORT    DataHTask
  4534.     ENDIF
  4535.  
  4536.     IF GENERATING68K THEN
  4537.         Macro
  4538.         _DataHScheduleData
  4539.             dc.w     $2F3C
  4540.             dc.w     $0018
  4541.             dc.w     $000E
  4542.             moveq    #0,d0
  4543.             dc.w     $A82A
  4544.         EndM
  4545.     ELSE
  4546.         IMPORT    DataHScheduleData
  4547.     ENDIF
  4548.  
  4549.     IF GENERATING68K THEN
  4550.         Macro
  4551.         _DataHFinishData
  4552.             dc.w     $2F3C
  4553.             dc.w     $0006
  4554.             dc.w     $000F
  4555.             moveq    #0,d0
  4556.             dc.w     $A82A
  4557.         EndM
  4558.     ELSE
  4559.         IMPORT    DataHFinishData
  4560.     ENDIF
  4561.  
  4562.     IF GENERATING68K THEN
  4563.         Macro
  4564.         _DataHFlushCache
  4565.             dc.w     $2F3C
  4566.             dc.w     $0000
  4567.             dc.w     $0010
  4568.             moveq    #0,d0
  4569.             dc.w     $A82A
  4570.         EndM
  4571.     ELSE
  4572.         IMPORT    DataHFlushCache
  4573.     ENDIF
  4574.  
  4575.     IF GENERATING68K THEN
  4576.         Macro
  4577.         _DataHResolveDataRef
  4578.             dc.w     $2F3C
  4579.             dc.w     $000A
  4580.             dc.w     $0011
  4581.             moveq    #0,d0
  4582.             dc.w     $A82A
  4583.         EndM
  4584.     ELSE
  4585.         IMPORT    DataHResolveDataRef
  4586.     ENDIF
  4587.  
  4588.     IF GENERATING68K THEN
  4589.         Macro
  4590.         _DataHGetFileSize
  4591.             dc.w     $2F3C
  4592.             dc.w     $0004
  4593.             dc.w     $0012
  4594.             moveq    #0,d0
  4595.             dc.w     $A82A
  4596.         EndM
  4597.     ELSE
  4598.         IMPORT    DataHGetFileSize
  4599.     ENDIF
  4600.  
  4601.     IF GENERATING68K THEN
  4602.         Macro
  4603.         _DataHCanUseDataRef
  4604.             dc.w     $2F3C
  4605.             dc.w     $0008
  4606.             dc.w     $0013
  4607.             moveq    #0,d0
  4608.             dc.w     $A82A
  4609.         EndM
  4610.     ELSE
  4611.         IMPORT    DataHCanUseDataRef
  4612.     ENDIF
  4613.  
  4614.     IF GENERATING68K THEN
  4615.         Macro
  4616.         _DataHGetVolumeList
  4617.             dc.w     $2F3C
  4618.             dc.w     $0004
  4619.             dc.w     $0014
  4620.             moveq    #0,d0
  4621.             dc.w     $A82A
  4622.         EndM
  4623.     ELSE
  4624.         IMPORT    DataHGetVolumeList
  4625.     ENDIF
  4626.  
  4627.     IF GENERATING68K THEN
  4628.         Macro
  4629.         _DataHWrite
  4630.             dc.w     $2F3C
  4631.             dc.w     $0014
  4632.             dc.w     $0015
  4633.             moveq    #0,d0
  4634.             dc.w     $A82A
  4635.         EndM
  4636.     ELSE
  4637.         IMPORT    DataHWrite
  4638.     ENDIF
  4639.  
  4640.     IF GENERATING68K THEN
  4641.         Macro
  4642.         _DataHPreextend
  4643.             dc.w     $2F3C
  4644.             dc.w     $0008
  4645.             dc.w     $0016
  4646.             moveq    #0,d0
  4647.             dc.w     $A82A
  4648.         EndM
  4649.     ELSE
  4650.         IMPORT    DataHPreextend
  4651.     ENDIF
  4652.  
  4653.     IF GENERATING68K THEN
  4654.         Macro
  4655.         _DataHSetFileSize
  4656.             dc.w     $2F3C
  4657.             dc.w     $0004
  4658.             dc.w     $0017
  4659.             moveq    #0,d0
  4660.             dc.w     $A82A
  4661.         EndM
  4662.     ELSE
  4663.         IMPORT    DataHSetFileSize
  4664.     ENDIF
  4665.  
  4666.     IF GENERATING68K THEN
  4667.         Macro
  4668.         _DataHGetFreeSpace
  4669.             dc.w     $2F3C
  4670.             dc.w     $0004
  4671.             dc.w     $0018
  4672.             moveq    #0,d0
  4673.             dc.w     $A82A
  4674.         EndM
  4675.     ELSE
  4676.         IMPORT    DataHGetFreeSpace
  4677.     ENDIF
  4678.  
  4679.     IF GENERATING68K THEN
  4680.         Macro
  4681.         _DataHCreateFile
  4682.             dc.w     $2F3C
  4683.             dc.w     $0006
  4684.             dc.w     $0019
  4685.             moveq    #0,d0
  4686.             dc.w     $A82A
  4687.         EndM
  4688.     ELSE
  4689.         IMPORT    DataHCreateFile
  4690.     ENDIF
  4691.  
  4692.     IF GENERATING68K THEN
  4693.         Macro
  4694.         _DataHGetPreferredBlockSize
  4695.             dc.w     $2F3C
  4696.             dc.w     $0004
  4697.             dc.w     $001A
  4698.             moveq    #0,d0
  4699.             dc.w     $A82A
  4700.         EndM
  4701.     ELSE
  4702.         IMPORT    DataHGetPreferredBlockSize
  4703.     ENDIF
  4704.  
  4705.     IF GENERATING68K THEN
  4706.         Macro
  4707.         _DataHGetDeviceIndex
  4708.             dc.w     $2F3C
  4709.             dc.w     $0004
  4710.             dc.w     $001B
  4711.             moveq    #0,d0
  4712.             dc.w     $A82A
  4713.         EndM
  4714.     ELSE
  4715.         IMPORT    DataHGetDeviceIndex
  4716.     ENDIF
  4717.  
  4718.     IF GENERATING68K THEN
  4719.         Macro
  4720.         _DataHIsStreamingDataHandler
  4721.             dc.w     $2F3C
  4722.             dc.w     $0004
  4723.             dc.w     $001C
  4724.             moveq    #0,d0
  4725.             dc.w     $A82A
  4726.         EndM
  4727.     ELSE
  4728.         IMPORT    DataHIsStreamingDataHandler
  4729.     ENDIF
  4730.  
  4731.     IF GENERATING68K THEN
  4732.         Macro
  4733.         _DataHGetDataInBuffer
  4734.             dc.w     $2F3C
  4735.             dc.w     $0008
  4736.             dc.w     $001D
  4737.             moveq    #0,d0
  4738.             dc.w     $A82A
  4739.         EndM
  4740.     ELSE
  4741.         IMPORT    DataHGetDataInBuffer
  4742.     ENDIF
  4743.  
  4744.     IF GENERATING68K THEN
  4745.         Macro
  4746.         _DataHGetScheduleAheadTime
  4747.             dc.w     $2F3C
  4748.             dc.w     $0004
  4749.             dc.w     $001E
  4750.             moveq    #0,d0
  4751.             dc.w     $A82A
  4752.         EndM
  4753.     ELSE
  4754.         IMPORT    DataHGetScheduleAheadTime
  4755.     ENDIF
  4756.  
  4757.     IF GENERATING68K THEN
  4758.         Macro
  4759.         _DataHSetCacheSizeLimit
  4760.             dc.w     $2F3C
  4761.             dc.w     $0004
  4762.             dc.w     $001F
  4763.             moveq    #0,d0
  4764.             dc.w     $A82A
  4765.         EndM
  4766.     ELSE
  4767.         IMPORT    DataHSetCacheSizeLimit
  4768.     ENDIF
  4769.  
  4770.     IF GENERATING68K THEN
  4771.         Macro
  4772.         _DataHGetCacheSizeLimit
  4773.             dc.w     $2F3C
  4774.             dc.w     $0004
  4775.             dc.w     $0020
  4776.             moveq    #0,d0
  4777.             dc.w     $A82A
  4778.         EndM
  4779.     ELSE
  4780.         IMPORT    DataHGetCacheSizeLimit
  4781.     ENDIF
  4782.  
  4783.     IF GENERATING68K THEN
  4784.         Macro
  4785.         _DataHPlaybackHints
  4786.             dc.w     $2F3C
  4787.             dc.w     $0010
  4788.             dc.w     $0103
  4789.             moveq    #0,d0
  4790.             dc.w     $A82A
  4791.         EndM
  4792.     ELSE
  4793.         IMPORT    DataHPlaybackHints
  4794.     ENDIF
  4795.  
  4796.  
  4797. kDataHGetDataSelect                EQU        $2
  4798. kDataHPutDataSelect                EQU        $3
  4799. kDataHFlushDataSelect            EQU        $4
  4800. kDataHOpenForWriteSelect        EQU        $5
  4801. kDataHCloseForWriteSelect        EQU        $6
  4802. kDataHOpenForReadSelect            EQU        $8
  4803. kDataHCloseForReadSelect        EQU        $9
  4804. kDataHSetDataRefSelect            EQU        $A
  4805. kDataHGetDataRefSelect            EQU        $B
  4806. kDataHCompareDataRefSelect        EQU        $C
  4807. kDataHTaskSelect                EQU        $D
  4808. kDataHScheduleDataSelect        EQU        $E
  4809. kDataHFinishDataSelect            EQU        $F
  4810. kDataHFlushCacheSelect            EQU        $10
  4811. kDataHResolveDataRefSelect        EQU        $11
  4812. kDataHGetFileSizeSelect            EQU        $12
  4813. kDataHCanUseDataRefSelect        EQU        $13
  4814. kDataHGetVolumeListSelect        EQU        $14
  4815. kDataHWriteSelect                EQU        $15
  4816. kDataHPreextendSelect            EQU        $16
  4817. kDataHSetFileSizeSelect            EQU        $17
  4818. kDataHGetFreeSpaceSelect        EQU        $18
  4819. kDataHCreateFileSelect            EQU        $19
  4820. kDataHGetPreferredBlockSizeSelect EQU        $1A
  4821. kDataHGetDeviceIndexSelect        EQU        $1B
  4822. kDataHIsStreamingDataHandlerSelect EQU        $1C
  4823. kDataHGetDataInBufferSelect        EQU        $1D
  4824. kDataHGetScheduleAheadTimeSelect EQU        $1E
  4825. kDataHSetCacheSizeLimitSelect    EQU        $1F
  4826. kDataHGetCacheSizeLimitSelect    EQU        $20
  4827. kDataHPlaybackHintsSelect        EQU        $103
  4828.  
  4829. kMusicComponentType                EQU        'musi'
  4830.  
  4831. ; MusicSynthesizerFlags
  4832. kSynthesizerDynamicVoice        EQU        1                    ; can reassign voices/channels (else, hogs all channels in mask 
  4833. kSynthesizerUsesMIDIPort        EQU        2                    ; must be patched through MIDI Manager 
  4834. kSynthesizerMicrotone            EQU        4                    ; can play microtonal scales 
  4835. kSynthesizerLimitedMicrotone    EQU        8                    ; can play microtones, but only on 1-voice parts 
  4836. kSynthesizerMixedDrums            EQU        16                    ; any part can play drum parts, total = instrument parts 
  4837. kSynthesizerSoftware            EQU        32                    ; implemented in main CPU software == uses cpu cycles 
  4838. kSynthesizerGMSuperset            EQU        8192
  4839. kSynthesizerGM                    EQU        16384                ; synth is a GM device 
  4840.  
  4841. ;
  4842. ; * Note that these controller numbers
  4843. ; * are _not_ identical to the MIDI controller numbers.
  4844. ; * These are _signed_ 8.8 values, and the LSB's are
  4845. ; * always sent to a MIDI device. Controllers 32-63 are
  4846. ; * reserved (for MIDI, they are LSB's for 0-31, but we
  4847. ; * always send both).
  4848. ; *
  4849. ; * The full range, therefore, is -128.00 to 127.7f.
  4850. ; *
  4851. ; * _Excepting_ _volume_, all controls default to zero.
  4852. ; *
  4853. ; * Pitch bend is specified in fractional semitones! No
  4854. ; * more "pitch bend range" nonsense. You can bend as far
  4855. ; * as you want, any time you want.
  4856. kControllerModulationWheel        EQU        1
  4857. kControllerBreath                EQU        2
  4858. kControllerFoot                    EQU        4
  4859. kControllerPortamentoTime        EQU        5
  4860. kControllerVolume                EQU        7
  4861. kControllerBalance                EQU        8
  4862. kControllerPan                    EQU        10                    ; 0 - "default", 1 - n: positioned in output 1-n (incl fractions) 
  4863. kControllerExpression            EQU        11
  4864. kControllerPitchBend            EQU        32                    ; positive & negative semitones, with 7 bits fraction 
  4865. kControllerAfterTouch            EQU        33
  4866. kControllerSustain                EQU        64                    ; boolean - positive for on, 0 or negative off 
  4867. kControllerPortamento            EQU        65                    ; boolean 
  4868. kControllerSostenuto            EQU        66                    ; boolean 
  4869. kControllerSoftPedal            EQU        67                    ; boolean 
  4870. kControllerReverb                EQU        91
  4871. kControllerTremolo                EQU        92
  4872. kControllerChorus                EQU        93
  4873. kControllerCeleste                EQU        94
  4874. kControllerPhaser                EQU        95
  4875.  
  4876. kControllerMaximum                EQU        $7FFF                ; +01111111.11111111 
  4877. kControllerMinimum                EQU        $8000                ; -10000000.00000000 
  4878.  
  4879. SynthesizerDescription     RECORD    0
  4880. synthesizerType             ds.l    1                                    ; synthesizer type (must be same as component subtype) 
  4881. name                     ds.l    8                                    ; text name of synthesizer type 
  4882. flags                     ds.l    1                                    ; from the above enum 
  4883. voiceCount                 ds.l    1                                    ; maximum polyphony 
  4884. partCount                 ds.l    1                                    ; maximum multi-timbrality (and midi channels) 
  4885. instrumentCount             ds.l    1                                    ; non gm, built in (rom) instruments only 
  4886. modifiableInstrumentCount ds.l    1                                    ; plus n-more are user modifiable 
  4887. channelMask                 ds.l    1                                    ; (midi device only) which channels device always uses 
  4888. drumPartCount             ds.l    1                                    ; maximum multi-timbrality of drum parts 
  4889. drumCount                 ds.l    1                                    ; non gm, built in (rom) drumkits only 
  4890. modifiableDrumCount         ds.l    1                                    ; plus n-more are user modifiable 
  4891. drumChannelMask             ds.l    1                                    ; (midi device only) which channels device always uses 
  4892. outputCount                 ds.l    1                                    ; number of audio outputs (usually two) 
  4893. latency                     ds.l    1                                    ; response time in µSec 
  4894. controllers                 ds.l    4                                    ; array of 128 bits 
  4895. gmInstruments             ds.l    4                                    ; array of 128 bits 
  4896. gmDrums                     ds.l    4                                    ; array of 128 bits 
  4897. sizeof                     EQU    132
  4898.                         ENDR
  4899.  
  4900.  
  4901. kVoiceCountDynamic                EQU        -1                    ; constant to use to specify dynamic voicing 
  4902.  
  4903. ToneDescription         RECORD    0
  4904. synthesizerType             ds.l    1                                    ; synthesizer type 
  4905. synthesizerName             ds.l    8                                    ; name of instantiation of synth 
  4906. instrumentName             ds.l    8                                    ; preferred name for human use 
  4907. instrumentNumber         ds.l    1                                    ; inst-number used if synth-name matches 
  4908. gmNumber                 ds.l    1                                    ; Best matching general MIDI number 
  4909. sizeof                     EQU    76
  4910.                         ENDR
  4911.  
  4912.  
  4913. kFirstDrumkit                    EQU        16384                ; (first value is "no drum". instrument numbers from 16384->16384+128 are drumkits, and for GM they are _defined_ drumkits! 
  4914. kLastDrumkit                    EQU        (kFirstDrumkit + 128)
  4915.  
  4916. ; InstrumentMatch
  4917. kInstrumentMatchSynthesizerType    EQU        1
  4918. kInstrumentMatchSynthesizerName    EQU        2
  4919. kInstrumentMatchName            EQU        4
  4920. kInstrumentMatchNumber            EQU        8
  4921. kInstrumentMatchGMNumber        EQU        16
  4922.  
  4923. ; KnobFlags
  4924. kKnobRealtime                    EQU        1                    ; Knob can be changed interactively as part of a sequence (ie knob can be changed at interrupt time) 
  4925. kKnobNextNote                    EQU        2                    ; Knob only takes effect on the next note played 
  4926. kKnobAction                        EQU        4                    ; setting the knob does something immediate 
  4927. kKnobNotInstrument                EQU        8                    ; indicates that the knob isn't in the instrument handle 
  4928. kKnobAffectsOthers                EQU        16                    ; other knobs will change value from this one 
  4929. kKnobMinorGroupStart            EQU        64                    ; knob is first in some logical subgroup of knobs 
  4930. kKnobGroupStart                    EQU        128                    ; knob is first in some logical group of knobs 
  4931. ; One of these may be used at a time. 
  4932. kKnobTypeNumber                    EQU        0 << 12
  4933. kKnobTypeBoolean                EQU        1 << 12
  4934. kKnobTypeNote                    EQU        2 << 12
  4935. kKnobTypePan                    EQU        3 << 12
  4936. kKnobTypeInstrument                EQU        4 << 12                ; knob value = reference to another instrument number 
  4937. kKnobTypeSetting                EQU        5 << 12                ; knob value is 1 of n different things (eg, fm algorithms) 
  4938.  
  4939. kUnknownKnobValue                EQU        $7FFFFFFF            ; a knob with this value means, we don't know it. 
  4940.  
  4941. KnobDescription         RECORD    0
  4942. name                     ds.l    8
  4943. lowValue                 ds.l    1
  4944. highValue                 ds.l    1
  4945. defaultValue             ds.l    1                                    ; a default instrument is made of all default values 
  4946. flags                     ds.l    1
  4947. sizeof                     EQU    48
  4948.                         ENDR
  4949.  
  4950. InstrumentData             RECORD    0
  4951. tone                     ds        ToneDescription
  4952. knobCount                 ds.l    1
  4953. knob                     ds.l    1
  4954. sizeof                     EQU    84
  4955.                         ENDR
  4956.  
  4957. FlatInstrument             RECORD    0
  4958. tone                     ds        ToneDescription
  4959. size                     ds.l    1                                    ; size in bytes of the following data, including size field (excluding tonedescription) 
  4960. data                     ds.b    4
  4961. sizeof                     EQU    84
  4962.                         ENDR
  4963.  
  4964. InstrumentAboutInfo     RECORD    0
  4965. p                         ds.l    1
  4966. author                     ds.l    64
  4967. copyright                 ds.l    64
  4968. other                     ds.l    64
  4969. sizeof                     EQU    772
  4970.                         ENDR
  4971.  
  4972. MusicMIDIPacket         RECORD    0
  4973. length                     ds.w    1
  4974. reserved                 ds.l    1
  4975. data                     ds.b    249
  4976. sizeof                     EQU    256
  4977.                         ENDR
  4978.  
  4979.  
  4980. kMusicFirstSelect                EQU        0
  4981. kMusicGetDescriptionSelect        EQU        1
  4982. kMusicGetPartSelect                EQU        2
  4983. kMusicSetPartSelect                EQU        3
  4984. kMusicSetInstrumentNumberSelect    EQU        4
  4985. kMusicGetInstrumentNumberSelect    EQU        5
  4986. kMusicStoreInstrumentSelect        EQU        6
  4987. kMusicGetInstrumentSelect        EQU        7
  4988. kMusicSetInstrumentSelect        EQU        8
  4989. kMusicDummyOne                    EQU        9
  4990. kMusicDummyTwo                    EQU        10
  4991. kMusicDummyThree                EQU        11
  4992. kMusicDummyFour                    EQU        12
  4993. kMusicGetInstrumentKnobDescriptionSelect EQU        13
  4994. kMusicGetDrumKnobDescriptionSelect EQU        14
  4995. kMusicGetKnobDescriptionSelect    EQU        15
  4996. kMusicGetPartKnobSelect            EQU        16
  4997. kMusicSetPartKnobSelect            EQU        17
  4998. kMusicGetKnobSelect                EQU        18
  4999. kMusicSetKnobSelect                EQU        19
  5000. kMusicGetPartNameSelect            EQU        20
  5001. kMusicSetPartNameSelect            EQU        21
  5002. kMusicFindToneSelect            EQU        22
  5003. kMusicPlayNoteSelect            EQU        23
  5004. kMusicResetPartSelect            EQU        24
  5005. kMusicSetControllerSelect        EQU        25
  5006. kMusicGetControllerSelect        EQU        26
  5007. kMusicGetMIDIProcSelect            EQU        27
  5008. kMusicSetMIDIProcSelect            EQU        28
  5009. kMusicGetInstrumentNamesSelect    EQU        29
  5010. kMusicGetDrumNamesSelect        EQU        30
  5011. kMusicGetMasterTuneSelect        EQU        31
  5012. kMusicSetMasterTuneSelect        EQU        32
  5013. kMusicSetFlatInstrumentSelect    EQU        33
  5014. kMusicGetInstrumentAboutInfoSelect EQU        34
  5015.  
  5016. notImplementedMusicErr            EQU        ($80000000 | ((-2100 - 1)))
  5017. cantSendToSynthesizerErr        EQU        ($80000000 | ((-2100 - 2)))
  5018. cantReceiveFromSynthesizerErr    EQU        ($80000000 | ((-2100 - 3)))
  5019. illegalVoiceAllocationErr        EQU        ($80000000 | ((-2100 - 4)))
  5020. illegalPartErr                    EQU        ($80000000 | ((-2100 - 5)))
  5021. illegalChannelErr                EQU        ($80000000 | ((-2100 - 6)))
  5022. illegalKnobErr                    EQU        ($80000000 | ((-2100 - 7)))
  5023. illegalKnobValueErr                EQU        ($80000000 | ((-2100 - 8)))
  5024. illegalInstrumentErr            EQU        ($80000000 | ((-2100 - 9)))
  5025. illegalControllerErr            EQU        ($80000000 | ((-2100 - 10)))
  5026. midiManagerAbsentErr            EQU        ($80000000 | ((-2100 - 11)))
  5027. synthesizerNotRespondingErr        EQU        ($80000000 | ((-2100 - 12)))
  5028. synthesizerErr                    EQU        ($80000000 | ((-2100 - 13)))
  5029. illegalNoteChannelErr            EQU        ($80000000 | ((-2100 - 14)))
  5030. noteChannelNotAllocatedErr        EQU        ($80000000 | ((-2100 - 15)))
  5031. tunePlayerFullErr                EQU        ($80000000 | ((-2100 - 16)))
  5032. tuneParseErr                    EQU        ($80000000 | ((-2100 - 17)))
  5033.  
  5034. kGMType                            EQU        'gm  '
  5035.  
  5036. ;-----------------------------------------
  5037. ;    Capabilities and Voice Allocation
  5038. ;-----------------------------------------
  5039.     IF GENERATING68K THEN
  5040.         Macro
  5041.         _MusicGetPart
  5042.             dc.w     $2F3C
  5043.             dc.w     $000C
  5044.             dc.w     $0002
  5045.             moveq    #0,d0
  5046.             dc.w     $A82A
  5047.         EndM
  5048.     ELSE
  5049.         IMPORT    MusicGetPart
  5050.     ENDIF
  5051.  
  5052.     IF GENERATING68K THEN
  5053.         Macro
  5054.         _MusicSetPart
  5055.             dc.w     $2F3C
  5056.             dc.w     $000C
  5057.             dc.w     $0003
  5058.             moveq    #0,d0
  5059.             dc.w     $A82A
  5060.         EndM
  5061.     ELSE
  5062.         IMPORT    MusicSetPart
  5063.     ENDIF
  5064.  
  5065.     IF GENERATING68K THEN
  5066.         Macro
  5067.         _MusicGetDescription
  5068.             dc.w     $2F3C
  5069.             dc.w     $0004
  5070.             dc.w     $0001
  5071.             moveq    #0,d0
  5072.             dc.w     $A82A
  5073.         EndM
  5074.     ELSE
  5075.         IMPORT    MusicGetDescription
  5076.     ENDIF
  5077.  
  5078.     IF GENERATING68K THEN
  5079.         Macro
  5080.         _MusicGetInstrumentAboutInfo
  5081.             dc.w     $2F3C
  5082.             dc.w     $0008
  5083.             dc.w     $0022
  5084.             moveq    #0,d0
  5085.             dc.w     $A82A
  5086.         EndM
  5087.     ELSE
  5088.         IMPORT    MusicGetInstrumentAboutInfo
  5089.     ENDIF
  5090.  
  5091. ;-----------------------------------------
  5092. ;    Instrument Loading and Storing
  5093. ;-----------------------------------------
  5094.     IF GENERATING68K THEN
  5095.         Macro
  5096.         _MusicSetInstrumentNumber
  5097.             dc.w     $2F3C
  5098.             dc.w     $0008
  5099.             dc.w     $0004
  5100.             moveq    #0,d0
  5101.             dc.w     $A82A
  5102.         EndM
  5103.     ELSE
  5104.         IMPORT    MusicSetInstrumentNumber
  5105.     ENDIF
  5106.  
  5107.     IF GENERATING68K THEN
  5108.         Macro
  5109.         _MusicGetInstrumentNumber
  5110.             dc.w     $2F3C
  5111.             dc.w     $0004
  5112.             dc.w     $0005
  5113.             moveq    #0,d0
  5114.             dc.w     $A82A
  5115.         EndM
  5116.     ELSE
  5117.         IMPORT    MusicGetInstrumentNumber
  5118.     ENDIF
  5119.  
  5120.     IF GENERATING68K THEN
  5121.         Macro
  5122.         _MusicStoreInstrument
  5123.             dc.w     $2F3C
  5124.             dc.w     $0008
  5125.             dc.w     $0006
  5126.             moveq    #0,d0
  5127.             dc.w     $A82A
  5128.         EndM
  5129.     ELSE
  5130.         IMPORT    MusicStoreInstrument
  5131.     ENDIF
  5132.  
  5133.     IF GENERATING68K THEN
  5134.         Macro
  5135.         _MusicGetInstrument
  5136.             dc.w     $2F3C
  5137.             dc.w     $0008
  5138.             dc.w     $0007
  5139.             moveq    #0,d0
  5140.             dc.w     $A82A
  5141.         EndM
  5142.     ELSE
  5143.         IMPORT    MusicGetInstrument
  5144.     ENDIF
  5145.  
  5146.     IF GENERATING68K THEN
  5147.         Macro
  5148.         _MusicSetInstrument
  5149.             dc.w     $2F3C
  5150.             dc.w     $0008
  5151.             dc.w     $0008
  5152.             moveq    #0,d0
  5153.             dc.w     $A82A
  5154.         EndM
  5155.     ELSE
  5156.         IMPORT    MusicSetInstrument
  5157.     ENDIF
  5158.  
  5159.     IF GENERATING68K THEN
  5160.         Macro
  5161.         _MusicSetFlatInstrument
  5162.             dc.w     $2F3C
  5163.             dc.w     $0008
  5164.             dc.w     $0021
  5165.             moveq    #0,d0
  5166.             dc.w     $A82A
  5167.         EndM
  5168.     ELSE
  5169.         IMPORT    MusicSetFlatInstrument
  5170.     ENDIF
  5171.  
  5172. ;-----------------------------------------
  5173. ;    Instrument Knobs
  5174. ;-----------------------------------------
  5175.     IF GENERATING68K THEN
  5176.         Macro
  5177.         _MusicGetInstrumentKnobDescription
  5178.             dc.w     $2F3C
  5179.             dc.w     $0008
  5180.             dc.w     $000D
  5181.             moveq    #0,d0
  5182.             dc.w     $A82A
  5183.         EndM
  5184.     ELSE
  5185.         IMPORT    MusicGetInstrumentKnobDescription
  5186.     ENDIF
  5187.  
  5188.     IF GENERATING68K THEN
  5189.         Macro
  5190.         _MusicGetDrumKnobDescription
  5191.             dc.w     $2F3C
  5192.             dc.w     $0008
  5193.             dc.w     $000E
  5194.             moveq    #0,d0
  5195.             dc.w     $A82A
  5196.         EndM
  5197.     ELSE
  5198.         IMPORT    MusicGetDrumKnobDescription
  5199.     ENDIF
  5200.  
  5201.     IF GENERATING68K THEN
  5202.         Macro
  5203.         _MusicGetPartKnob
  5204.             dc.w     $2F3C
  5205.             dc.w     $0008
  5206.             dc.w     $0010
  5207.             moveq    #0,d0
  5208.             dc.w     $A82A
  5209.         EndM
  5210.     ELSE
  5211.         IMPORT    MusicGetPartKnob
  5212.     ENDIF
  5213.  
  5214.     IF GENERATING68K THEN
  5215.         Macro
  5216.         _MusicSetPartKnob
  5217.             dc.w     $2F3C
  5218.             dc.w     $000C
  5219.             dc.w     $0011
  5220.             moveq    #0,d0
  5221.             dc.w     $A82A
  5222.         EndM
  5223.     ELSE
  5224.         IMPORT    MusicSetPartKnob
  5225.     ENDIF
  5226.  
  5227. ;-----------------------------------------
  5228. ;    Synthesizer Knobs
  5229. ;-----------------------------------------
  5230.     IF GENERATING68K THEN
  5231.         Macro
  5232.         _MusicGetKnobDescription
  5233.             dc.w     $2F3C
  5234.             dc.w     $0008
  5235.             dc.w     $000F
  5236.             moveq    #0,d0
  5237.             dc.w     $A82A
  5238.         EndM
  5239.     ELSE
  5240.         IMPORT    MusicGetKnobDescription
  5241.     ENDIF
  5242.  
  5243.     IF GENERATING68K THEN
  5244.         Macro
  5245.         _MusicGetKnob
  5246.             dc.w     $2F3C
  5247.             dc.w     $0004
  5248.             dc.w     $0012
  5249.             moveq    #0,d0
  5250.             dc.w     $A82A
  5251.         EndM
  5252.     ELSE
  5253.         IMPORT    MusicGetKnob
  5254.     ENDIF
  5255.  
  5256.     IF GENERATING68K THEN
  5257.         Macro
  5258.         _MusicSetKnob
  5259.             dc.w     $2F3C
  5260.             dc.w     $0008
  5261.             dc.w     $0013
  5262.             moveq    #0,d0
  5263.             dc.w     $A82A
  5264.         EndM
  5265.     ELSE
  5266.         IMPORT    MusicSetKnob
  5267.     ENDIF
  5268.  
  5269.     IF GENERATING68K THEN
  5270.         Macro
  5271.         _MusicSetMasterTune
  5272.             dc.w     $2F3C
  5273.             dc.w     $0004
  5274.             dc.w     $0020
  5275.             moveq    #0,d0
  5276.             dc.w     $A82A
  5277.         EndM
  5278.     ELSE
  5279.         IMPORT    MusicSetMasterTune
  5280.     ENDIF
  5281.  
  5282.     IF GENERATING68K THEN
  5283.         Macro
  5284.         _MusicGetMasterTune
  5285.             dc.w     $2F3C
  5286.             dc.w     $0000
  5287.             dc.w     $001F
  5288.             moveq    #0,d0
  5289.             dc.w     $A82A
  5290.         EndM
  5291.     ELSE
  5292.         IMPORT    MusicGetMasterTune
  5293.     ENDIF
  5294.  
  5295. ;-----------------------------------------
  5296. ;    Names of Instruments
  5297. ;-----------------------------------------
  5298.     IF GENERATING68K THEN
  5299.         Macro
  5300.         _MusicGetPartName
  5301.             dc.w     $2F3C
  5302.             dc.w     $0008
  5303.             dc.w     $0014
  5304.             moveq    #0,d0
  5305.             dc.w     $A82A
  5306.         EndM
  5307.     ELSE
  5308.         IMPORT    MusicGetPartName
  5309.     ENDIF
  5310.  
  5311.     IF GENERATING68K THEN
  5312.         Macro
  5313.         _MusicSetPartName
  5314.             dc.w     $2F3C
  5315.             dc.w     $0008
  5316.             dc.w     $0015
  5317.             moveq    #0,d0
  5318.             dc.w     $A82A
  5319.         EndM
  5320.     ELSE
  5321.         IMPORT    MusicSetPartName
  5322.     ENDIF
  5323.  
  5324.     IF GENERATING68K THEN
  5325.         Macro
  5326.         _MusicFindTone
  5327.             dc.w     $2F3C
  5328.             dc.w     $000C
  5329.             dc.w     $0016
  5330.             moveq    #0,d0
  5331.             dc.w     $A82A
  5332.         EndM
  5333.     ELSE
  5334.         IMPORT    MusicFindTone
  5335.     ENDIF
  5336.  
  5337.     IF GENERATING68K THEN
  5338.         Macro
  5339.         _MusicGetInstrumentNames
  5340.             dc.w     $2F3C
  5341.             dc.w     $0010
  5342.             dc.w     $001D
  5343.             moveq    #0,d0
  5344.             dc.w     $A82A
  5345.         EndM
  5346.     ELSE
  5347.         IMPORT    MusicGetInstrumentNames
  5348.     ENDIF
  5349.  
  5350.     IF GENERATING68K THEN
  5351.         Macro
  5352.         _MusicGetDrumNames
  5353.             dc.w     $2F3C
  5354.             dc.w     $000C
  5355.             dc.w     $001E
  5356.             moveq    #0,d0
  5357.             dc.w     $A82A
  5358.         EndM
  5359.     ELSE
  5360.         IMPORT    MusicGetDrumNames
  5361.     ENDIF
  5362.  
  5363. ;-----------------------------------------
  5364. ;    Realtime Actions
  5365. ;-----------------------------------------
  5366.     IF GENERATING68K THEN
  5367.         Macro
  5368.         _MusicPlayNote
  5369.             dc.w     $2F3C
  5370.             dc.w     $000C
  5371.             dc.w     $0017
  5372.             moveq    #0,d0
  5373.             dc.w     $A82A
  5374.         EndM
  5375.     ELSE
  5376.         IMPORT    MusicPlayNote
  5377.     ENDIF
  5378.  
  5379.     IF GENERATING68K THEN
  5380.         Macro
  5381.         _MusicResetPart
  5382.             dc.w     $2F3C
  5383.             dc.w     $0004
  5384.             dc.w     $0018
  5385.             moveq    #0,d0
  5386.             dc.w     $A82A
  5387.         EndM
  5388.     ELSE
  5389.         IMPORT    MusicResetPart
  5390.     ENDIF
  5391.  
  5392.     IF GENERATING68K THEN
  5393.         Macro
  5394.         _MusicSetController
  5395.             dc.w     $2F3C
  5396.             dc.w     $000C
  5397.             dc.w     $0019
  5398.             moveq    #0,d0
  5399.             dc.w     $A82A
  5400.         EndM
  5401.     ELSE
  5402.         IMPORT    MusicSetController
  5403.     ENDIF
  5404.  
  5405.     IF GENERATING68K THEN
  5406.         Macro
  5407.         _MusicGetController
  5408.             dc.w     $2F3C
  5409.             dc.w     $0008
  5410.             dc.w     $001A
  5411.             moveq    #0,d0
  5412.             dc.w     $A82A
  5413.         EndM
  5414.     ELSE
  5415.         IMPORT    MusicGetController
  5416.     ENDIF
  5417.  
  5418. ;-----------------------------------------
  5419. ;    Finding the Hardware
  5420. ;-----------------------------------------
  5421.     IF GENERATING68K THEN
  5422.         Macro
  5423.         _MusicGetMIDIProc
  5424.             dc.w     $2F3C
  5425.             dc.w     $0008
  5426.             dc.w     $001B
  5427.             moveq    #0,d0
  5428.             dc.w     $A82A
  5429.         EndM
  5430.     ELSE
  5431.         IMPORT    MusicGetMIDIProc
  5432.     ENDIF
  5433.  
  5434.     IF GENERATING68K THEN
  5435.         Macro
  5436.         _MusicSetMIDIProc
  5437.             dc.w     $2F3C
  5438.             dc.w     $0008
  5439.             dc.w     $001C
  5440.             moveq    #0,d0
  5441.             dc.w     $A82A
  5442.         EndM
  5443.     ELSE
  5444.         IMPORT    MusicSetMIDIProc
  5445.     ENDIF
  5446.  
  5447. ;--------------------------
  5448. ;    Types
  5449. ;--------------------------
  5450. SynthesizerConnections     RECORD    0
  5451. clientID                 ds.l    1
  5452. inputPortID                 ds.l    1
  5453. outputPortID             ds.l    1
  5454. midiChannel                 ds.l    1                                    ; The system channel; others are configurable (or the nubus slot number) 
  5455. flags                     ds.l    1
  5456. reserved                 ds.l    3                                    ; should be zero 
  5457. sizeof                     EQU    32
  5458.                         ENDR
  5459.  
  5460. NoteRequest             RECORD    0
  5461. polyphony                 ds.l    1                                    ; Maximum number of voices 
  5462. typicalPolyphony         ds.l    1                                    ; Hint for level mixing 
  5463. tone                     ds        ToneDescription
  5464. sizeof                     EQU    84
  5465.                         ENDR
  5466.  
  5467.  
  5468. kNAFirstSelector                EQU        -7
  5469. kNATargetSelect                    EQU        -6
  5470. kNARegisterSelect                EQU        -5
  5471. kNAVersionSelect                EQU        -4
  5472. kNACanDoSelect                    EQU        -3
  5473. kNACloseSelect                    EQU        -2
  5474. kNAOpenSelect                    EQU        -1
  5475. kNARegisterMusicDeviceSelect    EQU        0
  5476. kNAUnregisterMusicDeviceSelect    EQU        1
  5477. kNAGetRegisteredMusicDeviceSelect EQU        2
  5478. kNASaveMusicConfigurationSelect    EQU        3
  5479. kNANewNoteChannelSelect            EQU        4
  5480. kNADisposeNoteChannelSelect        EQU        5
  5481. kNAGetNoteChannelInfoSelect        EQU        6
  5482. kNAPrerollNoteChannelSelect        EQU        7
  5483. kNAUnrollNoteChannelSelect        EQU        8
  5484. kNAEngageNoteChannelSelect        EQU        9
  5485. kNADisengageNoteChannelSelect    EQU        10
  5486. kNASetNoteChannelVolumeSelect    EQU        11
  5487. kNAResetNoteChannelSelect        EQU        12
  5488. kNAPlayNoteSelect                EQU        13
  5489. kNASetControllerSelect            EQU        14
  5490. kNASetKnobSelect                EQU        15
  5491. kNAFindNoteChannelToneSelect    EQU        16
  5492. kNASetNoteChannelInstrumentSelect EQU        17
  5493. kNAPickInstrumentSelect            EQU        18
  5494. kNAPickArrangementSelect        EQU        19
  5495. kNAGetStatusBlockSelect            EQU        20
  5496. kNASetDefaultMIDIInputSelect    EQU        21
  5497. kNAGetDefaultMIDIInputSelect    EQU        22
  5498. kNAGetNoteChannelStateSelect    EQU        23
  5499. kNASetNoteChannelStateSelect    EQU        24
  5500. kNAUseDefaultMIDIInputSelect    EQU        25
  5501. kNALoseDefaultMIDIInputSelect    EQU        26
  5502. kNAStuffToneDescriptionSelect    EQU        27
  5503. kNACopyrightDialogSelect        EQU        28
  5504. kNASetFlatInstrumentSelect        EQU        29
  5505. kNASetInstrumentSelect            EQU        30
  5506. kNALastSelector                    EQU        31
  5507.  
  5508. kPickDontMix                    EQU        1                    ; dont mix instruments with drum sounds 
  5509. kPickSameSynth                    EQU        2                    ; only allow the same device that went in, to come out 
  5510.  
  5511. kNoteAllocatorType                EQU        'nota'
  5512.  
  5513. ;--------------------------------
  5514. ;    Note Allocator Prototypes
  5515. ;--------------------------------
  5516. ;
  5517. ; * System Configuration
  5518.     IF GENERATING68K THEN
  5519.         Macro
  5520.         _NARegisterMusicDevice
  5521.             dc.w     $2F3C
  5522.             dc.w     $000C
  5523.             dc.w     $0000
  5524.             moveq    #0,d0
  5525.             dc.w     $A82A
  5526.         EndM
  5527.     ELSE
  5528.         IMPORT    NARegisterMusicDevice
  5529.     ENDIF
  5530.  
  5531.     IF GENERATING68K THEN
  5532.         Macro
  5533.         _NAUnregisterMusicDevice
  5534.             dc.w     $2F3C
  5535.             dc.w     $0004
  5536.             dc.w     $0001
  5537.             moveq    #0,d0
  5538.             dc.w     $A82A
  5539.         EndM
  5540.     ELSE
  5541.         IMPORT    NAUnregisterMusicDevice
  5542.     ENDIF
  5543.  
  5544.     IF GENERATING68K THEN
  5545.         Macro
  5546.         _NAGetRegisteredMusicDevice
  5547.             dc.w     $2F3C
  5548.             dc.w     $0014
  5549.             dc.w     $0002
  5550.             moveq    #0,d0
  5551.             dc.w     $A82A
  5552.         EndM
  5553.     ELSE
  5554.         IMPORT    NAGetRegisteredMusicDevice
  5555.     ENDIF
  5556.  
  5557.     IF GENERATING68K THEN
  5558.         Macro
  5559.         _NASetDefaultMIDIInput
  5560.             dc.w     $2F3C
  5561.             dc.w     $0004
  5562.             dc.w     $0015
  5563.             moveq    #0,d0
  5564.             dc.w     $A82A
  5565.         EndM
  5566.     ELSE
  5567.         IMPORT    NASetDefaultMIDIInput
  5568.     ENDIF
  5569.  
  5570.     IF GENERATING68K THEN
  5571.         Macro
  5572.         _NAGetDefaultMIDIInput
  5573.             dc.w     $2F3C
  5574.             dc.w     $0004
  5575.             dc.w     $0016
  5576.             moveq    #0,d0
  5577.             dc.w     $A82A
  5578.         EndM
  5579.     ELSE
  5580.         IMPORT    NAGetDefaultMIDIInput
  5581.     ENDIF
  5582.  
  5583.     IF GENERATING68K THEN
  5584.         Macro
  5585.         _NASaveMusicConfiguration
  5586.             dc.w     $2F3C
  5587.             dc.w     $0000
  5588.             dc.w     $0003
  5589.             moveq    #0,d0
  5590.             dc.w     $A82A
  5591.         EndM
  5592.     ELSE
  5593.         IMPORT    NASaveMusicConfiguration
  5594.     ENDIF
  5595.  
  5596. ;
  5597. ; * Allocation
  5598.     IF GENERATING68K THEN
  5599.         Macro
  5600.         _NANewNoteChannel
  5601.             dc.w     $2F3C
  5602.             dc.w     $0008
  5603.             dc.w     $0004
  5604.             moveq    #0,d0
  5605.             dc.w     $A82A
  5606.         EndM
  5607.     ELSE
  5608.         IMPORT    NANewNoteChannel
  5609.     ENDIF
  5610.  
  5611.     IF GENERATING68K THEN
  5612.         Macro
  5613.         _NADisposeNoteChannel
  5614.             dc.w     $2F3C
  5615.             dc.w     $0004
  5616.             dc.w     $0005
  5617.             moveq    #0,d0
  5618.             dc.w     $A82A
  5619.         EndM
  5620.     ELSE
  5621.         IMPORT    NADisposeNoteChannel
  5622.     ENDIF
  5623.  
  5624.     IF GENERATING68K THEN
  5625.         Macro
  5626.         _NAGetNoteChannelInfo
  5627.             dc.w     $2F3C
  5628.             dc.w     $000C
  5629.             dc.w     $0006
  5630.             moveq    #0,d0
  5631.             dc.w     $A82A
  5632.         EndM
  5633.     ELSE
  5634.         IMPORT    NAGetNoteChannelInfo
  5635.     ENDIF
  5636.  
  5637.     IF GENERATING68K THEN
  5638.         Macro
  5639.         _NAUseDefaultMIDIInput
  5640.             dc.w     $2F3C
  5641.             dc.w     $000C
  5642.             dc.w     $0019
  5643.             moveq    #0,d0
  5644.             dc.w     $A82A
  5645.         EndM
  5646.     ELSE
  5647.         IMPORT    NAUseDefaultMIDIInput
  5648.     ENDIF
  5649.  
  5650.     IF GENERATING68K THEN
  5651.         Macro
  5652.         _NALoseDefaultMIDIInput
  5653.             dc.w     $2F3C
  5654.             dc.w     $0000
  5655.             dc.w     $001A
  5656.             moveq    #0,d0
  5657.             dc.w     $A82A
  5658.         EndM
  5659.     ELSE
  5660.         IMPORT    NALoseDefaultMIDIInput
  5661.     ENDIF
  5662.  
  5663. ;
  5664. ; * Setup
  5665.     IF GENERATING68K THEN
  5666.         Macro
  5667.         _NAPrerollNoteChannel
  5668.             dc.w     $2F3C
  5669.             dc.w     $0004
  5670.             dc.w     $0007
  5671.             moveq    #0,d0
  5672.             dc.w     $A82A
  5673.         EndM
  5674.     ELSE
  5675.         IMPORT    NAPrerollNoteChannel
  5676.     ENDIF
  5677.  
  5678.     IF GENERATING68K THEN
  5679.         Macro
  5680.         _NAUnrollNoteChannel
  5681.             dc.w     $2F3C
  5682.             dc.w     $0004
  5683.             dc.w     $0008
  5684.             moveq    #0,d0
  5685.             dc.w     $A82A
  5686.         EndM
  5687.     ELSE
  5688.         IMPORT    NAUnrollNoteChannel
  5689.     ENDIF
  5690.  
  5691.     IF GENERATING68K THEN
  5692.         Macro
  5693.         _NAEngageNoteChannel
  5694.             dc.w     $2F3C
  5695.             dc.w     $0004
  5696.             dc.w     $0009
  5697.             moveq    #0,d0
  5698.             dc.w     $A82A
  5699.         EndM
  5700.     ELSE
  5701.         IMPORT    NAEngageNoteChannel
  5702.     ENDIF
  5703.  
  5704.     IF GENERATING68K THEN
  5705.         Macro
  5706.         _NADisengageNoteChannel
  5707.             dc.w     $2F3C
  5708.             dc.w     $0008
  5709.             dc.w     $000A
  5710.             moveq    #0,d0
  5711.             dc.w     $A82A
  5712.         EndM
  5713.     ELSE
  5714.         IMPORT    NADisengageNoteChannel
  5715.     ENDIF
  5716.  
  5717.     IF GENERATING68K THEN
  5718.         Macro
  5719.         _NAGetNoteChannelState
  5720.             dc.w     $2F3C
  5721.             dc.w     $000C
  5722.             dc.w     $0017
  5723.             moveq    #0,d0
  5724.             dc.w     $A82A
  5725.         EndM
  5726.     ELSE
  5727.         IMPORT    NAGetNoteChannelState
  5728.     ENDIF
  5729.  
  5730.     IF GENERATING68K THEN
  5731.         Macro
  5732.         _NASetNoteChannelState
  5733.             dc.w     $2F3C
  5734.             dc.w     $000C
  5735.             dc.w     $0018
  5736.             moveq    #0,d0
  5737.             dc.w     $A82A
  5738.         EndM
  5739.     ELSE
  5740.         IMPORT    NASetNoteChannelState
  5741.     ENDIF
  5742.  
  5743.     IF GENERATING68K THEN
  5744.         Macro
  5745.         _NAResetNoteChannel
  5746.             dc.w     $2F3C
  5747.             dc.w     $0004
  5748.             dc.w     $000C
  5749.             moveq    #0,d0
  5750.             dc.w     $A82A
  5751.         EndM
  5752.     ELSE
  5753.         IMPORT    NAResetNoteChannel
  5754.     ENDIF
  5755.  
  5756.     IF GENERATING68K THEN
  5757.         Macro
  5758.         _NASetNoteChannelVolume
  5759.             dc.w     $2F3C
  5760.             dc.w     $0008
  5761.             dc.w     $000B
  5762.             moveq    #0,d0
  5763.             dc.w     $A82A
  5764.         EndM
  5765.     ELSE
  5766.         IMPORT    NASetNoteChannelVolume
  5767.     ENDIF
  5768.  
  5769.     IF GENERATING68K THEN
  5770.         Macro
  5771.         _NASetInstrument
  5772.             dc.w     $2F3C
  5773.             dc.w     $0008
  5774.             dc.w     $001E
  5775.             moveq    #0,d0
  5776.             dc.w     $A82A
  5777.         EndM
  5778.     ELSE
  5779.         IMPORT    NASetInstrument
  5780.     ENDIF
  5781.  
  5782.     IF GENERATING68K THEN
  5783.         Macro
  5784.         _NASetFlatInstrument
  5785.             dc.w     $2F3C
  5786.             dc.w     $0008
  5787.             dc.w     $001D
  5788.             moveq    #0,d0
  5789.             dc.w     $A82A
  5790.         EndM
  5791.     ELSE
  5792.         IMPORT    NASetFlatInstrument
  5793.     ENDIF
  5794.  
  5795. ;
  5796. ; * Control
  5797.     IF GENERATING68K THEN
  5798.         Macro
  5799.         _NAPlayNote
  5800.             dc.w     $2F3C
  5801.             dc.w     $000C
  5802.             dc.w     $000D
  5803.             moveq    #0,d0
  5804.             dc.w     $A82A
  5805.         EndM
  5806.     ELSE
  5807.         IMPORT    NAPlayNote
  5808.     ENDIF
  5809.  
  5810.     IF GENERATING68K THEN
  5811.         Macro
  5812.         _NASetController
  5813.             dc.w     $2F3C
  5814.             dc.w     $000C
  5815.             dc.w     $000E
  5816.             moveq    #0,d0
  5817.             dc.w     $A82A
  5818.         EndM
  5819.     ELSE
  5820.         IMPORT    NASetController
  5821.     ENDIF
  5822.  
  5823.     IF GENERATING68K THEN
  5824.         Macro
  5825.         _NASetKnob
  5826.             dc.w     $2F3C
  5827.             dc.w     $000C
  5828.             dc.w     $000F
  5829.             moveq    #0,d0
  5830.             dc.w     $A82A
  5831.         EndM
  5832.     ELSE
  5833.         IMPORT    NASetKnob
  5834.     ENDIF
  5835.  
  5836.     IF GENERATING68K THEN
  5837.         Macro
  5838.         _NAFindNoteChannelTone
  5839.             dc.w     $2F3C
  5840.             dc.w     $000C
  5841.             dc.w     $0010
  5842.             moveq    #0,d0
  5843.             dc.w     $A82A
  5844.         EndM
  5845.     ELSE
  5846.         IMPORT    NAFindNoteChannelTone
  5847.     ENDIF
  5848.  
  5849.     IF GENERATING68K THEN
  5850.         Macro
  5851.         _NASetNoteChannelInstrument
  5852.             dc.w     $2F3C
  5853.             dc.w     $0008
  5854.             dc.w     $0011
  5855.             moveq    #0,d0
  5856.             dc.w     $A82A
  5857.         EndM
  5858.     ELSE
  5859.         IMPORT    NASetNoteChannelInstrument
  5860.     ENDIF
  5861.  
  5862. ;
  5863. ; * User Interface
  5864.     IF GENERATING68K THEN
  5865.         Macro
  5866.         _NAPickInstrument
  5867.             dc.w     $2F3C
  5868.             dc.w     $001C
  5869.             dc.w     $0012
  5870.             moveq    #0,d0
  5871.             dc.w     $A82A
  5872.         EndM
  5873.     ELSE
  5874.         IMPORT    NAPickInstrument
  5875.     ENDIF
  5876.  
  5877.     IF GENERATING68K THEN
  5878.         Macro
  5879.         _NAStuffToneDescription
  5880.             dc.w     $2F3C
  5881.             dc.w     $0008
  5882.             dc.w     $001B
  5883.             moveq    #0,d0
  5884.             dc.w     $A82A
  5885.         EndM
  5886.     ELSE
  5887.         IMPORT    NAStuffToneDescription
  5888.     ENDIF
  5889.  
  5890.     IF GENERATING68K THEN
  5891.         Macro
  5892.         _NAPickArrangement
  5893.             dc.w     $2F3C
  5894.             dc.w     $0018
  5895.             dc.w     $0013
  5896.             moveq    #0,d0
  5897.             dc.w     $A82A
  5898.         EndM
  5899.     ELSE
  5900.         IMPORT    NAPickArrangement
  5901.     ENDIF
  5902.  
  5903.     IF GENERATING68K THEN
  5904.         Macro
  5905.         _NACopyrightDialog
  5906.             dc.w     $2F3C
  5907.             dc.w     $001C
  5908.             dc.w     $001C
  5909.             moveq    #0,d0
  5910.             dc.w     $A82A
  5911.         EndM
  5912.     ELSE
  5913.         IMPORT    NACopyrightDialog
  5914.     ENDIF
  5915.  
  5916. ;
  5917. ; * Note Allocator interior views
  5918. NAStatPiece             RECORD    0
  5919. clientName                 ds.l    8
  5920. synthesizerName             ds.l    8
  5921. part                     ds.l    1
  5922. midiChannel                 ds.l    1
  5923. polyphony                 ds.l    1
  5924. valid                     ds.l    1
  5925. sizeof                     EQU    80
  5926.                         ENDR
  5927.  
  5928. NAStat                     RECORD    0
  5929. pieceCount                 ds.l    1
  5930. piece                     ds.b    64 * NAStatPiece
  5931. sizeof                     EQU    5124
  5932.                         ENDR
  5933.  
  5934.     IF GENERATING68K THEN
  5935.         Macro
  5936.         _NAGetStatusBlock
  5937.             dc.w     $2F3C
  5938.             dc.w     $0004
  5939.             dc.w     $0014
  5940.             moveq    #0,d0
  5941.             dc.w     $A82A
  5942.         EndM
  5943.     ELSE
  5944.         IMPORT    NAGetStatusBlock
  5945.     ENDIF
  5946.  
  5947. ;--------------------------
  5948. ;    Types
  5949. ;--------------------------
  5950.  
  5951. kTuneQueueDepth                    EQU        8                    ; Deepest you can queue tune segments 
  5952.  
  5953. TuneStatus                 RECORD    0
  5954. tune                     ds.l    1                                    ; currently playing tune 
  5955. tunePtr                     ds.l    1                                    ; position within currently playing piece 
  5956. time                     ds.l    1                                    ; current tune time 
  5957. queueCount                 ds.w    1                                    ; how many pieces queued up? 
  5958. queueSpots                 ds.w    1                                    ; How many more tunepieces can be queued 
  5959. queueTime                 ds.l    1                                    ; How much time is queued up? (can be very inaccurate) 
  5960. reserved                 ds.l    3
  5961. sizeof                     EQU    32
  5962.                         ENDR
  5963.  
  5964.  
  5965. kStopTuneFade                    EQU        1                    ; do a quick, synchronous fadeout 
  5966. kStopTuneSustain                EQU        2                    ; don't silece notes 
  5967. kStopTuneInstant                EQU        4                    ; silence notes fast (else, decay them) 
  5968. kStopTuneReleaseChannels        EQU        8                    ; afterwards, let the channels go 
  5969.  
  5970. kTuneSelect                        EQU        3
  5971. kTuneSetHeaderSelect            EQU        4
  5972. kTuneGetTimeBaseSelect            EQU        5
  5973. kTuneSetTimeScaleSelect            EQU        6
  5974. kTuneGetTimeScaleSelect            EQU        7
  5975. kTuneGetIndexedNoteChannelSelect EQU        8
  5976. kTuneDummy                        EQU        9
  5977. kTuneQueueSelect                EQU        10
  5978. kTuneInstantSelect                EQU        11
  5979. kTuneGetStatusSelect            EQU        12
  5980. kTuneStopSelect                    EQU        13
  5981. kTuneResumeSelect                EQU        14
  5982. kTuneFlushSelect                EQU        15
  5983. kTuneSetVolumeSelect            EQU        16
  5984. kTuneGetVolumeSelect            EQU        17
  5985. kTunePrerollSelect                EQU        18
  5986. kTuneUnrollSelect                EQU        19
  5987. kTuneLastSelector                EQU        20
  5988.  
  5989. kMaxTunePlayerParts                EQU        32
  5990. kTunePlayerType                    EQU        'tune'
  5991.  
  5992. ;--------------------------
  5993. ;    Prototypes
  5994. ;--------------------------
  5995.     IF GENERATING68K THEN
  5996.         Macro
  5997.         _TuneSetHeader
  5998.             dc.w     $2F3C
  5999.             dc.w     $0004
  6000.             dc.w     $0004
  6001.             moveq    #0,d0
  6002.             dc.w     $A82A
  6003.         EndM
  6004.     ELSE
  6005.         IMPORT    TuneSetHeader
  6006.     ENDIF
  6007.  
  6008.     IF GENERATING68K THEN
  6009.         Macro
  6010.         _TuneGetTimeBase
  6011.             dc.w     $2F3C
  6012.             dc.w     $0004
  6013.             dc.w     $0005
  6014.             moveq    #0,d0
  6015.             dc.w     $A82A
  6016.         EndM
  6017.     ELSE
  6018.         IMPORT    TuneGetTimeBase
  6019.     ENDIF
  6020.  
  6021.     IF GENERATING68K THEN
  6022.         Macro
  6023.         _TuneSetTimeScale
  6024.             dc.w     $2F3C
  6025.             dc.w     $0004
  6026.             dc.w     $0006
  6027.             moveq    #0,d0
  6028.             dc.w     $A82A
  6029.         EndM
  6030.     ELSE
  6031.         IMPORT    TuneSetTimeScale
  6032.     ENDIF
  6033.  
  6034.     IF GENERATING68K THEN
  6035.         Macro
  6036.         _TuneGetTimeScale
  6037.             dc.w     $2F3C
  6038.             dc.w     $0004
  6039.             dc.w     $0007
  6040.             moveq    #0,d0
  6041.             dc.w     $A82A
  6042.         EndM
  6043.     ELSE
  6044.         IMPORT    TuneGetTimeScale
  6045.     ENDIF
  6046.  
  6047.     IF GENERATING68K THEN
  6048.         Macro
  6049.         _TuneGetIndexedNoteChannel
  6050.             dc.w     $2F3C
  6051.             dc.w     $0008
  6052.             dc.w     $0008
  6053.             moveq    #0,d0
  6054.             dc.w     $A82A
  6055.         EndM
  6056.     ELSE
  6057.         IMPORT    TuneGetIndexedNoteChannel
  6058.     ENDIF
  6059.  
  6060. ; Values for when to start. 
  6061. kTuneStartNow                    EQU        1                    ; start after buffer is implied 
  6062. kTuneDontClipNotes                EQU        2                    ; allow notes to finish their durations outside sample 
  6063. kTuneExcludeEdgeNotes            EQU        4                    ; dont play notes that start at end of tune 
  6064. kTuneStartNewMaster                EQU        16384
  6065.  
  6066.     IF GENERATING68K THEN
  6067.         Macro
  6068.         _TuneQueue
  6069.             dc.w     $2F3C
  6070.             dc.w     $001C
  6071.             dc.w     $000A
  6072.             moveq    #0,d0
  6073.             dc.w     $A82A
  6074.         EndM
  6075.     ELSE
  6076.         IMPORT    TuneQueue
  6077.     ENDIF
  6078.  
  6079.     IF GENERATING68K THEN
  6080.         Macro
  6081.         _TuneInstant
  6082.             dc.w     $2F3C
  6083.             dc.w     $0008
  6084.             dc.w     $000B
  6085.             moveq    #0,d0
  6086.             dc.w     $A82A
  6087.         EndM
  6088.     ELSE
  6089.         IMPORT    TuneInstant
  6090.     ENDIF
  6091.  
  6092.     IF GENERATING68K THEN
  6093.         Macro
  6094.         _TuneGetStatus
  6095.             dc.w     $2F3C
  6096.             dc.w     $0004
  6097.             dc.w     $000C
  6098.             moveq    #0,d0
  6099.             dc.w     $A82A
  6100.         EndM
  6101.     ELSE
  6102.         IMPORT    TuneGetStatus
  6103.     ENDIF
  6104.  
  6105. ; Values for when to start. 
  6106. kStopSustain                    EQU        1                    ; Leaves notes playing, not silent 
  6107. kStopFadeout                    EQU        2                    ; Does a synchronous fade-out 
  6108.  
  6109.     IF GENERATING68K THEN
  6110.         Macro
  6111.         _TuneStop
  6112.             dc.w     $2F3C
  6113.             dc.w     $0004
  6114.             dc.w     $000D
  6115.             moveq    #0,d0
  6116.             dc.w     $A82A
  6117.         EndM
  6118.     ELSE
  6119.         IMPORT    TuneStop
  6120.     ENDIF
  6121.  
  6122.     IF GENERATING68K THEN
  6123.         Macro
  6124.         _TuneResume
  6125.             dc.w     $2F3C
  6126.             dc.w     $0000
  6127.             dc.w     $000E
  6128.             moveq    #0,d0
  6129.             dc.w     $A82A
  6130.         EndM
  6131.     ELSE
  6132.         IMPORT    TuneResume
  6133.     ENDIF
  6134.  
  6135.     IF GENERATING68K THEN
  6136.         Macro
  6137.         _TuneFlush
  6138.             dc.w     $2F3C
  6139.             dc.w     $0000
  6140.             dc.w     $000F
  6141.             moveq    #0,d0
  6142.             dc.w     $A82A
  6143.         EndM
  6144.     ELSE
  6145.         IMPORT    TuneFlush
  6146.     ENDIF
  6147.  
  6148.     IF GENERATING68K THEN
  6149.         Macro
  6150.         _TuneSetVolume
  6151.             dc.w     $2F3C
  6152.             dc.w     $0004
  6153.             dc.w     $0010
  6154.             moveq    #0,d0
  6155.             dc.w     $A82A
  6156.         EndM
  6157.     ELSE
  6158.         IMPORT    TuneSetVolume
  6159.     ENDIF
  6160.  
  6161.     IF GENERATING68K THEN
  6162.         Macro
  6163.         _TuneGetVolume
  6164.             dc.w     $2F3C
  6165.             dc.w     $0000
  6166.             dc.w     $0011
  6167.             moveq    #0,d0
  6168.             dc.w     $A82A
  6169.         EndM
  6170.     ELSE
  6171.         IMPORT    TuneGetVolume
  6172.     ENDIF
  6173.  
  6174.     IF GENERATING68K THEN
  6175.         Macro
  6176.         _TunePreroll
  6177.             dc.w     $2F3C
  6178.             dc.w     $0000
  6179.             dc.w     $0012
  6180.             moveq    #0,d0
  6181.             dc.w     $A82A
  6182.         EndM
  6183.     ELSE
  6184.         IMPORT    TunePreroll
  6185.     ENDIF
  6186.  
  6187.     IF GENERATING68K THEN
  6188.         Macro
  6189.         _TuneUnroll
  6190.             dc.w     $2F3C
  6191.             dc.w     $0000
  6192.             dc.w     $0013
  6193.             moveq    #0,d0
  6194.             dc.w     $A82A
  6195.         EndM
  6196.     ELSE
  6197.         IMPORT    TuneUnroll
  6198.     ENDIF
  6199.  
  6200. ;     QuickTime Music Track Event Formats:
  6201. ;
  6202. ;    At this time, QuickTime music tracks support 5 different event types -- REST events,
  6203. ;    short NOTE events, short CONTROL events, short GENERAL events, Long NOTE events, 
  6204. ;    long CONTROL events, and variable GENERAL events.
  6205. ;        • REST Event (4 bytes/event):
  6206. ;    
  6207. ;            (0 0 0) (5-bit UNUSED) (24-bit Rest Duration)
  6208. ;        
  6209. ;        • Short NOTE Events (4 bytes/event):
  6210. ;    
  6211. ;            (0 0 1) (5-bit Instrument) (6-bit Pitch) (7-bit Volume) (11-bit Duration)
  6212. ;        
  6213. ;            where:    Pitch is offset by 32 (Actual pitch = pitch field + 32)
  6214. ;
  6215. ;        • Short CONTROL Events (4 bytes/event):
  6216. ;    
  6217. ;            (0 1 0) (5-bit Instrument) (8-bit Controller) (1-bit UNUSED) (1-bit Sign) (7-bit MSB) (7-bit LSB)
  6218. ;                                                                         ( or 15-bit Signed Value)
  6219. ;        • Short GENERAL Event (4 bytes/event):
  6220. ;    
  6221. ;            (0 1 1) (1-bit UNUSED) (12-bit Sub-Type) (16-bit Value)
  6222. ;    
  6223. ;        • Long NOTE Events (8 bytes/event):
  6224. ;    
  6225. ;            (1 0 0 1) (12-bit Instrument) (1-bit UNUSED) (7-bit Pitch) (1-bit UNUSED) (7-bit Volume)
  6226. ;            (1 0) (8-bit UNUSED) (22-bit Duration)
  6227. ;        
  6228. ;        • Long CONTROL Event (8 bytes/event):
  6229. ;        
  6230. ;            (1 0 1 0) (12-bit Instrument) (16-bit Value MSB) 
  6231. ;            (1 0) (14-bit Controller) (16-bit Value LSB)
  6232. ;    
  6233. ;        • Long KNOB Event (8 bytes/event):
  6234. ;    
  6235. ;            (1 0 1 1) (12-bit Sub-Type) (16-bit Value MSB)
  6236. ;            (1 0) (14-bit KNOB) (16-bit Value LSB)
  6237. ;    
  6238. ;        • Variable GENERAL Length Events (N bytes/event):
  6239. ;    
  6240. ;            (1 1 1 1) (12-bit Sub-Type) (16-bit Length)
  6241. ;                :
  6242. ;            (32-bit Data values)
  6243. ;                :
  6244. ;            (1 1) (14-bit UNUSED) (16-bit Length)
  6245. ;    
  6246. ;            where:    Length field is the number of LONG words in the record.
  6247. ;                    Lengths include the first and last long words (Minimum length = 2)
  6248. ;                
  6249. ;    The following event type values have not been used yet and are reserved for 
  6250. ;    future expansion:
  6251. ;        
  6252. ;        • (1 0 0 0)        (8 bytes/event)
  6253. ;        • (1 1 0 0)        (N bytes/event)
  6254. ;        • (1 1 0 1)        (N bytes/event)
  6255. ;        • (1 1 1 0)        (N bytes/event)
  6256. ;        
  6257. ;    For all events, the following generalizations apply:
  6258. ;    
  6259. ;        -    All duration values are specified in Millisecond units.
  6260. ;        -     Pitch values are intended to map directly to the MIDI key numbers.
  6261. ;        -    Controllers from 0 to 127 correspond to the standard MIDI controllers.
  6262. ;            Controllers greater than 127 correspond to other controls (i.e., Pitch Bend, 
  6263. ;            Key Pressure, and Channel Pressure).    
  6264. ;
  6265. ; Defines for the implemented music event data fields
  6266. kRestEventType                    EQU        $0                    ; lower 3-bits 
  6267. kNoteEventType                    EQU        $1                    ; lower 3-bits 
  6268. kControlEventType                EQU        $2                    ; lower 3-bits 
  6269. kMarkerEventType                EQU        $3                    ; lower 3-bits 
  6270. kUndefined1EventType            EQU        $8                    ; 4-bits 
  6271. kXNoteEventType                    EQU        $9                    ; 4-bits 
  6272. kXControlEventType                EQU        $A                    ; 4-bits 
  6273. kKnobEventType                    EQU        $B                    ; 4-bits 
  6274. kUndefined2EventType            EQU        $C                    ; 4-bits 
  6275. kUndefined3EventType            EQU        $D                    ; 4-bits 
  6276. kUndefined4EventType            EQU        $E                    ; 4-bits 
  6277. kGeneralEventType                EQU        $F                    ; 4-bits 
  6278. kXEventLengthBits                EQU        $2                    ; 2 bits: indicates 8-byte event record 
  6279. kGeneralEventLengthBits            EQU        $3                    ; 2 bits: indicates variable length event record 
  6280. kEventLen                        EQU        1                    ; length of events in long words 
  6281. kXEventLen                        EQU        2
  6282. kRestEventLen                    EQU        kEventLen            ; length of events in long words 
  6283. kNoteEventLen                    EQU        kEventLen
  6284. kControlEventLen                EQU        kEventLen
  6285. kMarkerEventLen                    EQU        kEventLen
  6286. kXNoteEventLen                    EQU        kXEventLen
  6287. kXControlEventLen                EQU        kXEventLen
  6288. kGeneralEventLen                EQU        kXEventLen            ; 2 or more, however 
  6289. ; Universal Event Defines
  6290. kEventLengthFieldPos            EQU        30                    ; by looking at these two bits of the 1st or last word              
  6291. kEventLengthFieldWidth            EQU        2                    ; of an event you can determine the event length                      
  6292. ; length field: 0 & 1 => 1 long; 2 => 2 longs; 3 => variable length 
  6293. kEventTypeFieldPos                EQU        29                    ; event type field for short events 
  6294. kEventTypeFieldWidth            EQU        3                    ; short type is 3 bits 
  6295. kXEventTypeFieldPos                EQU        28                    ; event type field for extended events 
  6296. kXEventTypeFieldWidth            EQU        4                    ; extended type is 4 bits 
  6297. kEventInstrumentFieldPos        EQU        24
  6298. kEventInstrumentFieldWidth        EQU        5
  6299. kXEventInstrumentFieldPos        EQU        16                    ; in the 1st long word 
  6300. kXEventInstrumentFieldWidth        EQU        12
  6301. ; Rest Events
  6302. kRestEventDurationFieldPos        EQU        0
  6303. kRestEventDurationFieldWidth    EQU        24
  6304. kRestEventDurationMax            EQU        ((1 << kRestEventDurationFieldWidth) - 1)
  6305. ; Note Events
  6306. kNoteEventPitchFieldPos            EQU        18
  6307. kNoteEventPitchFieldWidth        EQU        6
  6308. kNoteEventPitchOffset            EQU        32                    ; add to value in pitch field to get actual pitch 
  6309. kNoteEventVolumeFieldPos        EQU        11
  6310. kNoteEventVolumeFieldWidth        EQU        7
  6311. kNoteEventVolumeOffset            EQU        0                    ; add to value in volume field to get actual volume 
  6312. kNoteEventDurationFieldPos        EQU        0
  6313. kNoteEventDurationFieldWidth    EQU        11
  6314. kNoteEventDurationMax            EQU        ((1 << kNoteEventDurationFieldWidth) - 1)
  6315. kXNoteEventPitchFieldPos        EQU        0                    ; in the 1st long word 
  6316. kXNoteEventPitchFieldWidth        EQU        16
  6317. kXNoteEventDurationFieldPos        EQU        0                    ; in the 2nd long word 
  6318. kXNoteEventDurationFieldWidth    EQU        22
  6319. kXNoteEventDurationMax            EQU        ((1 << kXNoteEventDurationFieldWidth) - 1)
  6320. kXNoteEventVolumeFieldPos        EQU        22                    ; in the 2nd long word 
  6321. kXNoteEventVolumeFieldWidth        EQU        7
  6322. ; Control Events
  6323. kControlEventControllerFieldPos    EQU        16
  6324. kControlEventControllerFieldWidth EQU        8
  6325. kControlEventValueFieldPos        EQU        0
  6326. kControlEventValueFieldWidth    EQU        16
  6327. kXControlEventControllerFieldPos EQU        0                    ; in the 2nd long word 
  6328. kXControlEventControllerFieldWidth EQU        16
  6329. kXControlEventValueFieldPos        EQU        0                    ; in the 1st long word 
  6330. kXControlEventValueFieldWidth    EQU        16
  6331. ; Knob Events
  6332. kKnobEventValueHighFieldPos        EQU        0                    ; 1st long word 
  6333. kKnobEventValueHighFieldWidth    EQU        16
  6334. kKnobEventKnobFieldPos            EQU        16                    ; 2nd long word 
  6335. kKnobEventKnobFieldWidth        EQU        14
  6336. kKnobEventValueLowFieldPos        EQU        0                    ; 2nd long word 
  6337. kKnobEventValueLowFieldWidth    EQU        16
  6338. ; Marker Events
  6339. kMarkerEventSubtypeFieldPos        EQU        16
  6340. kMarkerEventSubtypeFieldWidth    EQU        8
  6341. kMarkerEventValueFieldPos        EQU        0
  6342. kMarkerEventValueFieldWidth        EQU        16
  6343. ; General Events
  6344. kGeneralEventSubtypeFieldPos    EQU        16                    ; in the last long word 
  6345. kGeneralEventSubtypeFieldWidth    EQU        14
  6346. kGeneralEventLengthFieldPos        EQU        0                    ; in the 1st & last long words 
  6347. kGeneralEventLengthFieldWidth    EQU        16
  6348.  
  6349. kGeneralEventNoteRequest        EQU        1                    ; Encapsulates NoteRequest data structure 
  6350. kGeneralEventInstrument            EQU        2                    ; Encapsulates poly, typical poly, followed by InstrumentData record 
  6351. kGeneralEventFlatInstrument        EQU        3                    ; Encapsulates poly, typical poly, followed by FlatInstrument record 
  6352. kGeneralEventPartName            EQU        4                    ; Brackets 2 longs follwed by a pascal string (padded to long alignment) 
  6353. kGeneralEventPartKey            EQU        5                    ; Brackets 2 longs 
  6354.  
  6355. TCSourceRefNameType                EQU        'name'
  6356.  
  6357. tcDropFrame                        EQU        1 << 0
  6358. tc24HourMax                        EQU        1 << 1
  6359. tcNegTimesOK                    EQU        1 << 2
  6360. tcCounter                        EQU        1 << 3
  6361.  
  6362. TimeCodeDef             RECORD    0
  6363. flags                     ds.l    1                                    ; drop-frame, etc.
  6364. fTimeScale                 ds.l    1                                    ; time scale of frameDuration (eg. 2997)
  6365. frameDuration             ds.l    1                                    ; duration of each frame (eg. 100)
  6366. numFrames                 ds.b    1                                    ; number of frames per second for timecode (eg. 30)
  6367. ; number of frames per tick for counter mode
  6368. padding                     ds.b    1                                    ; unused padding byte 
  6369. sizeof                     EQU    14
  6370.                         ENDR
  6371.  
  6372.  
  6373. tctNegFlag                        EQU        $80                    ; negative bit is in minutes
  6374.  
  6375. TimeCodeTime             RECORD    0
  6376. hours                     ds.b    1
  6377. minutes                     ds.b    1
  6378. seconds                     ds.b    1
  6379. frames                     ds.b    1
  6380. sizeof                     EQU    4
  6381.                         ENDR
  6382.  
  6383. TimeCodeCounter         RECORD    0
  6384. counter                     ds.l    1
  6385. sizeof                     EQU    4
  6386.                         ENDR
  6387.  
  6388. TimeCodeDescription     RECORD    0
  6389. ; standard sample description header
  6390. descSize                 ds.l    1
  6391. dataFormat                 ds.l    1
  6392. resvd1                     ds.l    1
  6393. resvd2                     ds.w    1
  6394. dataRefIndex             ds.w    1
  6395. ; timecode specific stuff
  6396. flags                     ds.l    1
  6397. timeCodeDef                 ds        TimeCodeDef
  6398. srcRef                     ds.l    1
  6399. sizeof                     EQU    38
  6400.                         ENDR
  6401.  
  6402.  
  6403. tcdfShowTimeCode                EQU        1 << 0
  6404.  
  6405. kTCGetCurrentTimeCodeSelect        EQU        257
  6406. kTCGetTimeCodeAtTimeSelect        EQU        258
  6407. kTCTimeCodeToStringSelect        EQU        259
  6408. kTCTimeCodeToFrameNumberSelect    EQU        260
  6409. kTCFrameNumberToTimeCodeSelect    EQU        261
  6410. kTCGetSourceRefSelect            EQU        262
  6411. kTCSetSourceRefSelect            EQU        263
  6412. kTCSetTimeCodeFlagsSelect        EQU        264
  6413. kTCGetTimeCodeFlagsSelect        EQU        265
  6414. kTCSetDisplayOptionsSelect        EQU        266
  6415. kTCGetDisplayOptionsSelect        EQU        267
  6416.  
  6417.     IF GENERATING68K THEN
  6418.         Macro
  6419.         _TCGetCurrentTimeCode
  6420.             dc.w     $2F3C
  6421.             dc.w     $0010
  6422.             dc.w     $0101
  6423.             moveq    #0,d0
  6424.             dc.w     $A82A
  6425.         EndM
  6426.     ELSE
  6427.         IMPORT    TCGetCurrentTimeCode
  6428.     ENDIF
  6429.  
  6430.     IF GENERATING68K THEN
  6431.         Macro
  6432.         _TCGetTimeCodeAtTime
  6433.             dc.w     $2F3C
  6434.             dc.w     $0014
  6435.             dc.w     $0102
  6436.             moveq    #0,d0
  6437.             dc.w     $A82A
  6438.         EndM
  6439.     ELSE
  6440.         IMPORT    TCGetTimeCodeAtTime
  6441.     ENDIF
  6442.  
  6443.     IF GENERATING68K THEN
  6444.         Macro
  6445.         _TCTimeCodeToFrameNumber
  6446.             dc.w     $2F3C
  6447.             dc.w     $000C
  6448.             dc.w     $0104
  6449.             moveq    #0,d0
  6450.             dc.w     $A82A
  6451.         EndM
  6452.     ELSE
  6453.         IMPORT    TCTimeCodeToFrameNumber
  6454.     ENDIF
  6455.  
  6456.     IF GENERATING68K THEN
  6457.         Macro
  6458.         _TCFrameNumberToTimeCode
  6459.             dc.w     $2F3C
  6460.             dc.w     $000C
  6461.             dc.w     $0105
  6462.             moveq    #0,d0
  6463.             dc.w     $A82A
  6464.         EndM
  6465.     ELSE
  6466.         IMPORT    TCFrameNumberToTimeCode
  6467.     ENDIF
  6468.  
  6469.     IF GENERATING68K THEN
  6470.         Macro
  6471.         _TCTimeCodeToString
  6472.             dc.w     $2F3C
  6473.             dc.w     $000C
  6474.             dc.w     $0103
  6475.             moveq    #0,d0
  6476.             dc.w     $A82A
  6477.         EndM
  6478.     ELSE
  6479.         IMPORT    TCTimeCodeToString
  6480.     ENDIF
  6481.  
  6482.     IF GENERATING68K THEN
  6483.         Macro
  6484.         _TCGetSourceRef
  6485.             dc.w     $2F3C
  6486.             dc.w     $0008
  6487.             dc.w     $0106
  6488.             moveq    #0,d0
  6489.             dc.w     $A82A
  6490.         EndM
  6491.     ELSE
  6492.         IMPORT    TCGetSourceRef
  6493.     ENDIF
  6494.  
  6495.     IF GENERATING68K THEN
  6496.         Macro
  6497.         _TCSetSourceRef
  6498.             dc.w     $2F3C
  6499.             dc.w     $0008
  6500.             dc.w     $0107
  6501.             moveq    #0,d0
  6502.             dc.w     $A82A
  6503.         EndM
  6504.     ELSE
  6505.         IMPORT    TCSetSourceRef
  6506.     ENDIF
  6507.  
  6508.     IF GENERATING68K THEN
  6509.         Macro
  6510.         _TCSetTimeCodeFlags
  6511.             dc.w     $2F3C
  6512.             dc.w     $0008
  6513.             dc.w     $0108
  6514.             moveq    #0,d0
  6515.             dc.w     $A82A
  6516.         EndM
  6517.     ELSE
  6518.         IMPORT    TCSetTimeCodeFlags
  6519.     ENDIF
  6520.  
  6521.     IF GENERATING68K THEN
  6522.         Macro
  6523.         _TCGetTimeCodeFlags
  6524.             dc.w     $2F3C
  6525.             dc.w     $0004
  6526.             dc.w     $0109
  6527.             moveq    #0,d0
  6528.             dc.w     $A82A
  6529.         EndM
  6530.     ELSE
  6531.         IMPORT    TCGetTimeCodeFlags
  6532.     ENDIF
  6533.  
  6534.     IF GENERATING68K THEN
  6535.         Macro
  6536.         _TCSetDisplayOptions
  6537.             dc.w     $2F3C
  6538.             dc.w     $0004
  6539.             dc.w     $010A
  6540.             moveq    #0,d0
  6541.             dc.w     $A82A
  6542.         EndM
  6543.     ELSE
  6544.         IMPORT    TCSetDisplayOptions
  6545.     ENDIF
  6546.  
  6547.     IF GENERATING68K THEN
  6548.         Macro
  6549.         _TCGetDisplayOptions
  6550.             dc.w     $2F3C
  6551.             dc.w     $0004
  6552.             dc.w     $010B
  6553.             moveq    #0,d0
  6554.             dc.w     $A82A
  6555.         EndM
  6556.     ELSE
  6557.         IMPORT    TCGetDisplayOptions
  6558.     ENDIF
  6559.  
  6560. ; UPP call backs 
  6561.     ENDIF ; __QUICKTIMECOMPONENTS__
  6562.